Browse Source

deleted OperationTests, only works with CustomImpl actually

malknet42 10 years ago
parent
commit
7ead911959

+ 1 - 13
test-plugins/org.yakindu.sct.generator.cpp.test/model/test.sgen

@@ -384,19 +384,7 @@ GeneratorModel for sctunit::cpp {
 			WrapToJUnit =  "true"
 		}			
 	}
-	
-	test Operations{
-		
-		feature Outlet{ 
-			targetProject = "org.yakindu.sct.generator.cpp.test" 
-			targetFolder = "test-gen"			
-		}		
-		
-		feature JUnitWrapper {
-			WrapToJUnit =  "true"
-		}			
-	}
-	
+
 	test OutEventLifeCycle{
 		
 		feature Outlet{ 

+ 2 - 3
test-plugins/org.yakindu.sct.generator.cpp.test/test-gen/org/yakindu/sct/generator/cpp/test/AllTestsTest.java

@@ -27,9 +27,8 @@ import org.junit.runners.Suite.SuiteClasses;
 		InEventLifeCycleTest.class, IntegerExpressionsTest.class,
 		InternalEventLifeCycleTest.class, LocalReactionsTest.class,
 		LogicalAndTestsTest.class, LogicalOrTestsTest.class,
-		NamedInterfaceAccessTest.class, OperationsTest.class,
-		OutEventLifeCycleTest.class, ParenthesisTest.class,
-		PriorityValuesTest.class, RaiseEventTest.class,
+		NamedInterfaceAccessTest.class, OutEventLifeCycleTest.class,
+		ParenthesisTest.class, PriorityValuesTest.class, RaiseEventTest.class,
 		SameNameDifferentRegionTest.class, ShallowHistoryTest.class,
 		SimpleEventTest.class, StatechartLocalReactionsTest.class,
 		SimpleHierachyTest.class, StateIsActiveTest.class,

+ 0 - 39
test-plugins/org.yakindu.sct.generator.cpp.test/test-gen/org/yakindu/sct/generator/cpp/test/OperationsTest.java

@@ -1,39 +0,0 @@
-/**
- * Copyright (c) 2014 committers of YAKINDU and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- *     committers of YAKINDU - initial API and implementation
- */
-package org.yakindu.sct.generator.cpp.test;
-
-import java.util.Collection;
-
-import org.junit.Before;
-import org.junit.runner.RunWith;
-import org.yakindu.sct.generator.c.gtest.GTest;
-import org.yakindu.sct.generator.c.gtest.GTestRunner;
-import org.yakindu.sct.generator.c.gtest.GTestHelper;
-
-@GTest(sourceFile = "gtests/OperationsTest/OperationsTest.cc", program = "gtests/OperationsTest/Operations", model = "testmodels/SCTUnit/Operations.sct")
-@RunWith(GTestRunner.class)
-public class OperationsTest {
-
-	protected final GTestHelper helper = new GTestHelper(this) {
-
-		@Override
-		protected void getSourceFiles(Collection<String> files) {
-			super.getSourceFiles(files);
-			files.add(getFileName(getTestProgram()) + ".cpp");
-		}
-	};
-
-	@Before
-	public void setUp() {
-		helper.generate();
-		helper.compile();
-	}
-}

+ 0 - 8
test-plugins/org.yakindu.sct.generator.java.test/model/test.sgen

@@ -258,14 +258,6 @@ GeneratorModel for sctunit::java {
 		}			
 	}
 	
-	test Operations{
-		
-		feature Outlet{ 
-			targetProject = "org.yakindu.sct.generator.java.test" 
-			targetFolder = "test-gen"			
-		}			
-	}
-	
 	test OutEventLifeCycle{
 		
 		feature Outlet{ 

+ 0 - 43
test-plugins/org.yakindu.sct.generator.java.test/test-gen/org/yakindu/sct/generator/java/test/OperationsTest.java

@@ -1,43 +0,0 @@
-/**
- * Copyright (c) 2014 committers of YAKINDU and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- *     committers of YAKINDU - initial API and implementation
- */
-
-package org.yakindu.sct.generator.java.test;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import static org.junit.Assert.*;
-import org.yakindu.scr.operations.OperationsStatemachine;
-import org.yakindu.scr.operations.OperationsStatemachine.State;
-/**
- *  Unit TestCase for Operations
- */
-@SuppressWarnings("all")
-public class OperationsTest {
-
-	private OperationsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new OperationsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testOperationCallback() {
-		statemachine.enter();
-	}
-}

+ 0 - 8
test-plugins/org.yakindu.sct.simulation.core.sexec.test/model/test.sgen

@@ -258,14 +258,6 @@ GeneratorModel for sctunit::interpreter {
 		}			
 	}
 
-	test Operations{
-		
-		feature Outlet{ 
-			targetProject = "org.yakindu.sct.simulation.core.sexec.test" 
-			targetFolder = "test-gen"			
-		}			
-	}	
-	
 	test OutEventLifeCycle{
 		
 		feature Outlet{ 

+ 2 - 3
test-plugins/org.yakindu.sct.simulation.core.sexec.test/test-gen/org/yakindu/sct/simulation/core/sexec/test/AllTestsTest.java

@@ -28,9 +28,8 @@ import org.junit.runners.Suite.SuiteClasses;
 		InEventLifeCycleTest.class, IntegerExpressionsTest.class,
 		InternalEventLifeCycleTest.class, LocalReactionsTest.class,
 		LogicalAndTestsTest.class, LogicalOrTestsTest.class,
-		NamedInterfaceAccessTest.class, OperationsTest.class,
-		OutEventLifeCycleTest.class, ParenthesisTest.class,
-		PriorityValuesTest.class, RaiseEventTest.class,
+		NamedInterfaceAccessTest.class, OutEventLifeCycleTest.class,
+		ParenthesisTest.class, PriorityValuesTest.class, RaiseEventTest.class,
 		SameNameDifferentRegionTest.class, ShallowHistoryTest.class,
 		SimpleEventTest.class, StatechartLocalReactionsTest.class,
 		SimpleHierachyTest.class, StateIsActiveTest.class,

+ 0 - 49
test-plugins/org.yakindu.sct.simulation.core.sexec.test/test-gen/org/yakindu/sct/simulation/core/sexec/test/OperationsTest.java

@@ -1,49 +0,0 @@
-/**
- * Copyright (c) 2014 committers of YAKINDU and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- *     committers of YAKINDU - initial API and implementation
- */
-package org.yakindu.sct.simulation.core.sexec.test;
-import org.eclipse.xtext.junit4.InjectWith;
-import org.eclipse.xtext.junit4.XtextRunner;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.yakindu.sct.model.sexec.ExecutionFlow;
-import org.yakindu.sct.model.sexec.interpreter.test.util.AbstractExecutionFlowTest;
-import org.yakindu.sct.model.sexec.interpreter.test.util.SExecInjectionProvider;
-import org.yakindu.sct.test.models.SCTUnitTestModels;
-import com.google.inject.Inject;
-import static org.junit.Assert.assertTrue;
-/**
- *  Unit TestCase for Operations
- */
-@SuppressWarnings("all")
-@RunWith(XtextRunner.class)
-@InjectWith(SExecInjectionProvider.class)
-public class OperationsTest extends AbstractExecutionFlowTest {
-	@Before
-	public void setup() throws Exception {
-		ExecutionFlow flow = models
-				.loadExecutionFlowFromResource("Operations.sct");
-		initInterpreter(flow);
-	}
-	@Test
-	public void OperationCallback() throws Exception {
-		interpreter.enter();
-		assertTrue(isActive("A"));
-		interpreter.runCycle();
-		assertTrue(isActive("B"));
-		raiseEvent("ev");
-		interpreter.runCycle();
-		assertTrue(isActive("C"));
-		raiseEvent("ev");
-		interpreter.runCycle();
-		assertTrue(isActive("D"));
-	}
-}

+ 0 - 1
test-plugins/org.yakindu.sct.test.models/tests/AllTests.sctunit

@@ -29,7 +29,6 @@ testsuite AllTests {
 	LogicalAndTests, 
 	LogicalOrTests,
 	NamedInterfaceAccess,
-//	Operations,
 	OutEventLifeCycle,
 	Parenthesis,
 //	PerformanceTests, 

+ 0 - 7
test-plugins/org.yakindu.sct.test.models/tests/Operations.sctunit

@@ -1,7 +0,0 @@
-
-testgroup Operations for statechart Operations {
-	test OperationCallback {
-		enter
-	} 
-}  
-