Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: f9b6b0e88285c084e6d6fa43a3383af69938df47 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
/*******************************************************************************
 * Copyright (c) 2014, 2015 Borland Software Corporation and others.
 * 
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v2.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v20.html
 * 
 * Contributors:
 *     Borland Software Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.m2m.tests.qvt.oml.transform;

import java.util.Arrays;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameters;

import junit.framework.AssertionFailedError;

@RunWith(Parameterized.class)
public class TestIncorrectTransformation extends TestQvtInterpreter {

	public TestIncorrectTransformation(ModelTestData data) {
		super(data);
	}
	
	@Parameters(name="{0}")
	public static Iterable<ModelTestData> data() {    	
		return Arrays.asList(
			new ModelTestData[] {	
				new ReferencedProjectData("bug433937_wrongImport", "bug433937_referenced", false) { //$NON-NLS-1$ //$NON-NLS-2$
					@Override
					public boolean isUseCompiledXmi() {
						// TODO it should be possible to run this test with the
						// using of compiled XMI
						return false;
					}
				},		
				new ReferencedProjectData("bug433937_wrongImport", "bug433937_referenced", true) { //$NON-NLS-1$ //$NON-NLS-2$
					@Override
					public boolean isUseCompiledXmi() {
						// TODO it should be possible to run this test with the
						// using of compiled XMI
						return false;
					}
				}
			}
		);
	}
	
	@Override
	protected void onBuildFailed(Throwable e) {
		if (e instanceof AssertionFailedError) {
			// it's compilation error so skip it
			return;
		}
		
		super.onBuildFailed(e);
	}
	
	@Override
	@Test
	public void runTest() throws Exception {
		// skip test execution since it's failed to build
	}

}

Back to the top