Selaa lähdekoodia

Bugfix in java code generator. Added testcase for declarations.

markus.muehlbrandt@gmail.com 13 vuotta sitten
vanhempi
commit
1e2afe3f87
43 muutettua tiedostoa jossa 2544 lisäystä ja 1806 poistoa
  1. 45 45
      plugins/org.yakindu.sct.generator.c/src/org/yakindu/sct/generator/c/templates/CustomStatemachineH.xpt
  2. 16 32
      plugins/org.yakindu.sct.generator.java/src/org/yakindu/sct/generator/java/FlowCode.xtend
  3. 26 52
      plugins/org.yakindu.sct.generator.java/src/org/yakindu/sct/generator/java/Statemachine.xtend
  4. 11 1
      test-plugins/org.yakindu.sct.generator.java.test/model/model.sgen
  5. 582 0
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/declarations/DeclarationsStatemachine.java
  6. 50 0
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/declarations/IDeclarationsStatemachine.java
  7. 5 0
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/exitonselftransition/ExitOnSelfTransitionStatemachine.java
  8. 30 30
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AllTestsTest.java
  9. 55 55
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AlwaysOncycleTest.java
  10. 45 45
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AssignmentAsExpressionTest.java
  11. 54 54
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/BitExpressionsTest.java
  12. 53 53
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/BooleanExpressionsTest.java
  13. 49 49
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/CKeywordsTest.java
  14. 70 70
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ChoiceTest.java
  15. 42 0
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/DeclarationsTest.java
  16. 63 63
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/DeepHistoryTest.java
  17. 53 53
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ExitOnSelfTransitionTest.java
  18. 45 45
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/FeatureCallsTest.java
  19. 58 58
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardTest.java
  20. 82 82
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardedEntryTest.java
  21. 58 58
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardedExitTest.java
  22. 64 64
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/IntegerExpressionsTest.java
  23. 58 58
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/InternalEventLifeCycleTest.java
  24. 44 44
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ParenthesisTest.java
  25. 92 92
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/PerformanceTestsTest.java
  26. 55 55
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/PriorityValuesTest.java
  27. 49 49
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/RaiseEventTest.java
  28. 53 53
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SameNameDifferentRegionTest.java
  29. 81 81
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ShallowHistoryTest.java
  30. 49 49
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SimpleEventTest.java
  31. 50 50
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SimpleHietachyTest.java
  32. 49 49
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StateIsActiveTest.java
  33. 53 53
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StatechartLocalReactionsTest.java
  34. 50 50
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StringExpressionsTest.java
  35. 61 61
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SyncForkTest.java
  36. 106 106
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SyncJoinTest.java
  37. 46 46
      test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ValuedEventTest.java
  38. 1 0
      test-plugins/org.yakindu.sct.test.models/.settings/org.eclipse.core.resources.prefs
  39. BIN
      test-plugins/org.yakindu.sct.test.models/images/Declarations.png
  40. 11 0
      test-plugins/org.yakindu.sct.test.models/src/util/TestModels.java
  41. 72 0
      test-plugins/org.yakindu.sct.test.models/testmodels/Declarations.sct
  42. 1 1
      test-plugins/org.yakindu.sct.test.models/tests/AllTests.sctunit
  43. 7 0
      test-plugins/org.yakindu.sct.test.models/tests/Declarations.sctunit

+ 45 - 45
plugins/org.yakindu.sct.generator.c/src/org/yakindu/sct/generator/c/templates/CustomStatemachineH.xpt

@@ -1,32 +1,32 @@
-«REM»
+«REM»
 
 
 Templates for the main statechart cpp file.
 Templates for the main statechart cpp file.
 
 
 @auther joern seger
 @auther joern seger
 
 
-«ENDREM»
+«ENDREM»
 
 
-«IMPORT sexec»
-«IMPORT stext»
-«IMPORT sgraph»
+«IMPORT sexec»
+«IMPORT stext»
+«IMPORT sgraph»
 
 
-«EXTENSION org::yakindu::sct::generator::c::templates::Expression»
-«EXTENSION org::yakindu::sct::generator::c::templates::Constants»
-«EXTENSION org::yakindu::sct::generator::c::templates::Naming»
+«EXTENSION org::yakindu::sct::generator::c::templates::Expression»
+«EXTENSION org::yakindu::sct::generator::c::templates::Constants»
+«EXTENSION org::yakindu::sct::generator::c::templates::Naming»
 
 
-«DEFINE file FOR ExecutionFlow»
+«DEFINE file FOR ExecutionFlow»
 
 
-«FILE StName()+'.h'»
-«this.getLicenseHeader()»
+«FILE StName()+'.h'»
+«this.getLicenseHeader()»
 
 
-#ifndef «STNAME()»_H_
-#define «STNAME()»_H_
+#ifndef «STNAME()»_H_
+#define «STNAME()»_H_
  
  
-«FOREACH this.scopes.getUsableScopes() AS interface -»
-#include "«interface.interfaceClassName()».h"
-«ENDFOREACH»
+«FOREACH this.scopes.getUsableScopes() AS interface -»
+#include "«interface.interfaceClassName()».h"
+«ENDFOREACH»
 #include "Statemachine_cy.h"
 #include "Statemachine_cy.h"
-#include "«EvName()».h"
+#include "«EvName()».h"
 #include "EventPool.h"
 #include "EventPool.h"
 #include "States.h"
 #include "States.h"
 
 
@@ -34,62 +34,62 @@ Templates for the main statechart cpp file.
 extern "C" {
 extern "C" {
 #endif 
 #endif 
 
 
-#define MAX_PARALLEL_STATES «this.stateVector.size»
-«IF historyVector == null»
+#define MAX_PARALLEL_STATES «this.stateVector.size»
+«IF historyVector == null»
 #define MAX_HISTORY_STATES 0
 #define MAX_HISTORY_STATES 0
-«ELSE»
-#define MAX_HISTORY_STATES «historyVector.size»
-«ENDIF»
+«ELSE»
+#define MAX_HISTORY_STATES «historyVector.size»
+«ENDIF»
 
 
 typedef void(*raiseEventFPtr)(_Event* evPtr);
 typedef void(*raiseEventFPtr)(_Event* evPtr);
 
 
 typedef struct {
 typedef struct {
 
 
 	Statemachine_cy base;
 	Statemachine_cy base;
-«FOREACH this.scopes.getUsableScopes() AS interface -»
-	«interface.interfaceClassName()» «interface.interfaceObjectName().toFirstLower()»;
-«ENDFOREACH -»
+«FOREACH this.scopes.getUsableScopes() AS interface -»
+	«interface.interfaceClassName()» «interface.interfaceObjectName().toFirstLower()»;
+«ENDFOREACH -»
 	raiseEventFPtr raiseEvent;
 	raiseEventFPtr raiseEvent;
 	
 	
-} «StName()»;
+} «StName()»;
 
 
 /* Explicit Constructor & Destructor */
 /* Explicit Constructor & Destructor */
-extern void «stName()»_init(«this.handleAdditionComma()» Timer* timer, EventPool* eventPool);
-extern void «stName()»_enter(«this.handleAddition()»);
-extern void «stName()»_exit(«this.handleAddition()»);
-extern void «stName()»_destruct(«this.handleAddition()»);
-extern void «stName()»_runCycle(«this.handleAddition()»);
-extern sc_boolean «stName()»_eventWaiting(«this.handleAddition()»);
+extern void «stName()»_init(«this.handleAdditionComma()» Timer* timer, EventPool* eventPool);
+extern void «stName()»_enter(«this.handleAddition()»);
+extern void «stName()»_exit(«this.handleAddition()»);
+extern void «stName()»_destruct(«this.handleAddition()»);
+extern void «stName()»_runCycle(«this.handleAddition()»);
+extern sc_boolean «stName()»_eventWaiting(«this.handleAddition()»);
 
 
-«FOREACH this.scopes.typeSelect(InterfaceScope) AS interface -»
-extern «interface.interfaceClassName()»* «stName()»_get_«interface.interfaceObjectName()»(«this.handleAddition()»);
-«ENDFOREACH -»
+«FOREACH this.scopes.typeSelect(InterfaceScope) AS interface -»
+extern «interface.interfaceClassName()»* «stName()»_get_«interface.interfaceObjectName()»(«this.handleAddition()»);
+«ENDFOREACH -»
 
 
-«IF this.isSingleton() == true»
-«StName()»* «scName()»_get_handle();
-«ENDIF»
+«IF this.isSingleton() == true»
+«StName()»* «scName()»_get_handle();
+«ENDIF»
 
 
 
 
-#define «scName()»_eventPool_init_heap(handle, maxElemPerEvent) eventPool_init_heap(handle, event_last, maxElemPerEvent, &«scName()»_getSizeofEvent )
+#define «scName()»_eventPool_init_heap(handle, maxElemPerEvent) eventPool_init_heap(handle, event_last, maxElemPerEvent, &«scName()»_getSizeofEvent )
 
 
 /* only friends can see these functions */
 /* only friends can see these functions */
-#ifdef «STNAME()»_FRIENDS
+#ifdef «STNAME()»_FRIENDS
 
 
-extern void «stName()»_setEvent(«this.handleAdditionComma()»_Event* ev);
+extern void «stName()»_setEvent(«this.handleAdditionComma()»_Event* ev);
 
 
 
 
 /* virtual function form state machine must be implemented here */
 /* virtual function form state machine must be implemented here */
 extern void statemachine_cy__runCycle(Statemachine_cy* handle);
 extern void statemachine_cy__runCycle(Statemachine_cy* handle);
 
 
-#endif /* «STNAME()»_FRIENDS */
+#endif /* «STNAME()»_FRIENDS */
 
 
 #ifdef __cplusplus
 #ifdef __cplusplus
 }
 }
 #endif 
 #endif 
  
  
-#endif /* «STNAME()»_H_ */
+#endif /* «STNAME()»_H_ */
 
 
-«ENDFILE»
+«ENDFILE»
 
 
-«ENDDEFINE»
+«ENDDEFINE»
 
 

+ 16 - 32
plugins/org.yakindu.sct.generator.java/src/org/yakindu/sct/generator/java/FlowCode.xtend

@@ -66,43 +66,36 @@ class FlowCode {
 		'''
 		'''
 	}
 	}
 	
 	
-	def dispatch code(Call it) {
-		'''
+	def dispatch code(Call it) '''
 		«step.functionName()»();
 		«step.functionName()»();
-		'''
-	}
+	'''
 	
 	
 	def dispatch code(Sequence it) {
 	def dispatch code(Sequence it) {
 		steps.map[code].join('\n')
 		steps.map[code].join('\n')
 	}
 	}
 	
 	
-	def dispatch code(Check it) {
-		'''
+	def dispatch code(Check it) '''
 		«IF this != null»
 		«IF this != null»
 			«condition.code()»
 			«condition.code()»
 		«ELSE»
 		«ELSE»
 			true
 			true
  		«ENDIF»
  		«ENDIF»
-		'''
-	}
+	'''
 	
 	
-	def dispatch code(CheckRef it) {
-		'''
+	def dispatch code(CheckRef it) '''
 		«IF check != null»
 		«IF check != null»
 			«comment»
 			«comment»
 			«check.functionName()»()
 			«check.functionName()»()
 		«ELSE»
 		«ELSE»
 			true
 			true
 		«ENDIF»
 		«ENDIF»
-		'''
-	}
+	'''
 	
 	
 	def dispatch code(Reaction it) {
 	def dispatch code(Reaction it) {
 		effect.code
 		effect.code
 	}
 	}
 	
 	
-	def dispatch code(If it) {
-		'''
+	def dispatch code(If it) '''
 		«stepComment»
 		«stepComment»
 		if («check.code») { 
 		if («check.code») { 
 			«thenStep.code»
 			«thenStep.code»
@@ -112,42 +105,33 @@ class FlowCode {
 			«elseStep.code»
 			«elseStep.code»
 		}
 		}
 		«ENDIF»
 		«ENDIF»
-		'''
-	}
+	'''
 	
 	
-	def dispatch code(EnterState it) {
-		'''
+	def dispatch code(EnterState it) '''
 		«stepComment»
 		«stepComment»
 		nextStateIndex = «state.stateVector.offset»;
 		nextStateIndex = «state.stateVector.offset»;
 		stateVector[«state.stateVector.offset»] = State.«state.stateName.asEscapedIdentifier»;
 		stateVector[«state.stateVector.offset»] = State.«state.stateName.asEscapedIdentifier»;
-		'''
-	}
+	'''
 	
 	
-	def dispatch code(ExitState it) {
-		'''
+	def dispatch code(ExitState it) '''
 		«stepComment»
 		«stepComment»
 		nextStateIndex = «state.stateVector.offset»;
 		nextStateIndex = «state.stateVector.offset»;
 		stateVector[«state.stateVector.offset»] = State.«getNullStateName()»;
 		stateVector[«state.stateVector.offset»] = State.«getNullStateName()»;
-		'''
-	}
+	'''
 	
 	
-	def dispatch code(HistoryEntry it) {
-		'''
+	def dispatch code(HistoryEntry it) '''
 		«stepComment»
 		«stepComment»
 		if (historyVector[«region.historyVector.offset»] != State.$NullState$) {
 		if (historyVector[«region.historyVector.offset»] != State.$NullState$) {
 			«historyStep.code»
 			«historyStep.code»
 		} else {
 		} else {
 			«initialStep.code»
 			«initialStep.code»
 		}
 		}
-		'''
-	}
+	'''
 	
 	
-	def dispatch code(SaveHistory it) {
-		'''
+	def dispatch code(SaveHistory it) '''
 		«stepComment»
 		«stepComment»
 		historyVector[«region.historyVector.offset»] = stateVector[«region.stateVector.offset»];
 		historyVector[«region.historyVector.offset»] = stateVector[«region.stateVector.offset»];
-		'''
-	}
+	'''
 	
 	
 	def String getInitialValueAssignment(VariableDefinition it) {
 	def String getInitialValueAssignment(VariableDefinition it) {
 		if (initialValue != null) {
 		if (initialValue != null) {

+ 26 - 52
plugins/org.yakindu.sct.generator.java/src/org/yakindu/sct/generator/java/Statemachine.xtend

@@ -72,8 +72,7 @@ class Statemachine {
 		}
 		}
 	'''
 	'''
 	
 	
-	def private createImports(ExecutionFlow flow, GeneratorEntry entry) {
-		'''
+	def private createImports(ExecutionFlow flow, GeneratorEntry entry) '''
 		«IF entry.createInterfaceObserver && flow.hasOutgoingEvents»
 		«IF entry.createInterfaceObserver && flow.hasOutgoingEvents»
 		import java.util.LinkedList;
 		import java.util.LinkedList;
 		import java.util.List;
 		import java.util.List;
@@ -82,11 +81,9 @@ class Statemachine {
 			import «entry.getBasePackageName()».TimeEvent;
 			import «entry.getBasePackageName()».TimeEvent;
 			import «entry.getBasePackageName()».ITimerService;
 			import «entry.getBasePackageName()».ITimerService;
 		«ENDIF»
 		«ENDIF»
-		'''
-	}
+	'''
 	
 	
-	def private createFieldDeclarations(ExecutionFlow flow, GeneratorEntry entry) {
-		'''
+	def private createFieldDeclarations(ExecutionFlow flow, GeneratorEntry entry) '''
 		«FOR event : flow.internalScopeEvents»
 		«FOR event : flow.internalScopeEvents»
 		private boolean «event.name.asEscapedIdentifier»;
 		private boolean «event.name.asEscapedIdentifier»;
 		
 		
@@ -138,11 +135,9 @@ class Statemachine {
 			private «internal.getInternalOperationCallbackName()» operationCallback;
 			private «internal.getInternalOperationCallbackName()» operationCallback;
 		«ENDIF»
 		«ENDIF»
 		«ENDFOR»
 		«ENDFOR»
-		'''
-	}
+	'''
 	
 	
-	def private createConstructor(ExecutionFlow flow) {
-		'''
+	def private createConstructor(ExecutionFlow flow) '''
 		public «flow.statemachineClassName»() {
 		public «flow.statemachineClassName»() {
 			
 			
 			«FOR scope : flow.interfaceScopes»
 			«FOR scope : flow.interfaceScopes»
@@ -153,11 +148,9 @@ class Statemachine {
 				«timeEvent.name.asEscapedIdentifier».setStatemachine(this);
 				«timeEvent.name.asEscapedIdentifier».setStatemachine(this);
 			«ENDFOR»
 			«ENDFOR»
 			}
 			}
-		'''
-	}
+	'''
 	
 	
-	def private initFunction(ExecutionFlow flow) {
-		'''
+	def private initFunction(ExecutionFlow flow) '''
 		public void init() {
 		public void init() {
 			«IF flow.timed»
 			«IF flow.timed»
 			if (timerService == null) {
 			if (timerService == null) {
@@ -176,11 +169,9 @@ class Statemachine {
 			clearEvents();
 			clearEvents();
 			clearOutEvents();
 			clearOutEvents();
 		}
 		}
-		'''
-	}
+	'''
 	
 	
-	def private clearInEventsFunction(ExecutionFlow flow) {
-		'''
+	def private clearInEventsFunction(ExecutionFlow flow) '''
 		protected void clearEvents() {
 		protected void clearEvents() {
 			«FOR scope : flow.interfaceScopes»
 			«FOR scope : flow.interfaceScopes»
 				«IF scope.hasEvents»
 				«IF scope.hasEvents»
@@ -199,11 +190,9 @@ class Statemachine {
 			}
 			}
 			«ENDIF»
 			«ENDIF»
 		}
 		}
-		'''
-	}
+	'''
 	
 	
-	def private clearOutEventsFunction(ExecutionFlow flow) {
-		'''
+	def private clearOutEventsFunction(ExecutionFlow flow) '''
 		protected void clearOutEvents() {
 		protected void clearOutEvents() {
 			«FOR scope : flow.interfaceScopes»
 			«FOR scope : flow.interfaceScopes»
 				«IF scope.hasOutgoingEvents»
 				«IF scope.hasOutgoingEvents»
@@ -211,11 +200,9 @@ class Statemachine {
 				«ENDIF»
 				«ENDIF»
 			«ENDFOR»
 			«ENDFOR»
 		}
 		}
-		'''
-	}
+	'''
 	
 	
-	def private isActiveFunction(ExecutionFlow flow) {
-		'''
+	def private isActiveFunction(ExecutionFlow flow) '''
 		public boolean isStateActive(State state){
 		public boolean isStateActive(State state){
 			switch (state) {
 			switch (state) {
 				«FOR s : flow.states»
 				«FOR s : flow.states»
@@ -227,11 +214,9 @@ class Statemachine {
 				default: return false;
 				default: return false;
 			}
 			}
 		}
 		}
-		'''
-	}
+	'''
 	
 	
-	def private timingFunctions(ExecutionFlow flow) {
-		'''
+	def private timingFunctions(ExecutionFlow flow) '''
 		«IF flow.timed»
 		«IF flow.timed»
 			public void setTimerService(ITimerService timerService) {
 			public void setTimerService(ITimerService timerService) {
 				this.timerService = timerService;
 				this.timerService = timerService;
@@ -245,21 +230,17 @@ class Statemachine {
 				timeEvents[timeEvent.getIndex()] = true;
 				timeEvents[timeEvent.getIndex()] = true;
 			}
 			}
 		«ENDIF»
 		«ENDIF»
-		'''
-	}
+	'''
 	
 	
-	def private interfaceAccessors(ExecutionFlow flow) {
-		'''
+	def private interfaceAccessors(ExecutionFlow flow) '''
 		«FOR scope : flow.interfaceScopes»
 		«FOR scope : flow.interfaceScopes»
 			public «scope.interfaceName» get«scope.interfaceName»() {
 			public «scope.interfaceName» get«scope.interfaceName»() {
 				return «scope.interfaceName.toFirstLower()»;
 				return «scope.interfaceName.toFirstLower()»;
 			}
 			}
 		«ENDFOR»
 		«ENDFOR»
-		'''
-	}
+	'''
 	
 	
-	def private toImplementation(InterfaceScope scope, GeneratorEntry entry) {
-		'''
+	def private toImplementation(InterfaceScope scope, GeneratorEntry entry) '''
 		private final class «scope.getInterfaceImplName» implements «scope.getInterfaceName» {
 		private final class «scope.getInterfaceImplName» implements «scope.getInterfaceName» {
 		
 		
 		«IF entry.createInterfaceObserver && scope.hasOutgoingEvents»
 		«IF entry.createInterfaceObserver && scope.hasOutgoingEvents»
@@ -377,16 +358,14 @@ class Statemachine {
 			}
 			}
 		«ENDIF»
 		«ENDIF»
 		}
 		}
-		'''
-	}
+	'''
 	
 	
 	def private getIllegalAccessValidation(EventDefinition it) '''
 	def private getIllegalAccessValidation(EventDefinition it) '''
 		if (! «name.asEscapedIdentifier» ) 
 		if (! «name.asEscapedIdentifier» ) 
 			throw new IllegalStateException("Illegal event value acces. Event «name.asEscapedName» is not raised!");
 			throw new IllegalStateException("Illegal event value acces. Event «name.asEscapedName» is not raised!");
 	'''
 	'''
 	
 	
-	def private internalScopeFunctions (ExecutionFlow flow) {
-		'''
+	def private internalScopeFunctions (ExecutionFlow flow) '''
 		«FOR event : flow.internalScopeEvents»
 		«FOR event : flow.internalScopeEvents»
 			«IF !event.type.void»
 			«IF !event.type.void»
 				private void raise«event.name.asEscapedName»(«event.type.getJavaType()» value) {
 				private void raise«event.name.asEscapedName»(«event.type.getJavaType()» value) {
@@ -408,7 +387,7 @@ class Statemachine {
 		«ENDFOR»
 		«ENDFOR»
 		«FOR variable : flow.internalScopeVariables»
 		«FOR variable : flow.internalScopeVariables»
 		private «variable.type.javaType» «variable.getter» {
 		private «variable.type.javaType» «variable.getter» {
-			return «variable.name.asEscapedName»;
+			return «variable.name.asEscapedIdentifier»;
 		}
 		}
 		
 		
 		private void «variable.setter»(«variable.type.javaType» value) {
 		private void «variable.setter»(«variable.type.javaType» value) {
@@ -425,10 +404,8 @@ class Statemachine {
 			«ENDIF»
 			«ENDIF»
 		«ENDFOR»
 		«ENDFOR»
 	'''
 	'''
-	}
 	
 	
-	def private defaultInterfaceFunctions(ExecutionFlow flow, GeneratorEntry entry) {
-		'''
+	def private defaultInterfaceFunctions(ExecutionFlow flow, GeneratorEntry entry) '''
 		«IF flow.defaultScope != null»
 		«IF flow.defaultScope != null»
 			«var InterfaceScope scope = flow.defaultScope»
 			«var InterfaceScope scope = flow.defaultScope»
 			«FOR event : scope.eventDefinitions»
 			«FOR event : scope.eventDefinitions»
@@ -466,11 +443,9 @@ class Statemachine {
 			«ENDFOR»
 			«ENDFOR»
 		«ENDIF»
 		«ENDIF»
 		
 		
-		'''
-	}
+	'''
 	
 	
-	def private runCycleFunction(ExecutionFlow flow) {
-		'''
+	def private runCycleFunction(ExecutionFlow flow) '''
 		public void runCycle() {
 		public void runCycle() {
 			
 			
 			«IF flow.timed»
 			«IF flow.timed»
@@ -496,8 +471,7 @@ class Statemachine {
 			
 			
 			clearEvents();
 			clearEvents();
 		}
 		}
-		'''
-	}
+	'''
 	
 	
 	def private enterFunction(ExecutionFlow it) '''
 	def private enterFunction(ExecutionFlow it) '''
 		public void enter() {
 		public void enter() {

+ 11 - 1
test-plugins/org.yakindu.sct.generator.java.test/model/model.sgen

@@ -350,5 +350,15 @@ GeneratorModel for yakindu::java {
 		}
 		}
 	}
 	}
 	
 	
-	
+	statechart Declarations {
+		feature Outlet {
+			targetProject = "org.yakindu.sct.generator.java.test"
+			targetFolder = "src-gen"
+		}
+
+		feature GeneralFeatures {
+			TimerService = true
+			RuntimeService = true
+		}
+	}
 }
 }

+ 582 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/declarations/DeclarationsStatemachine.java

@@ -0,0 +1,582 @@
+package org.yakindu.scr.declarations;
+
+public class DeclarationsStatemachine implements IDeclarationsStatemachine {
+
+	private boolean evInA;
+
+	private boolean evInB;
+
+	private boolean evInC;
+
+	private boolean evInCValue;
+	private boolean evInD;
+
+	private int evInDValue;
+	private boolean evInE;
+
+	private double evInEValue;
+	private boolean evInF;
+
+	private String evInFValue;
+
+	private final class SCIDefaultImpl implements SCIDefault {
+
+		private boolean evA;
+
+		public void raiseEvA() {
+			evA = true;
+		}
+
+		private boolean evB;
+
+		public boolean isRaisedEvB() {
+			return evB;
+		}
+
+		private void raiseEvB() {
+			evB = true;
+		}
+
+		private boolean evC;
+
+		private boolean evCValue;
+
+		public void raiseEvC(boolean value) {
+			evC = true;
+			evCValue = value;
+		}
+
+		private boolean getEvCValue() {
+			if (!evC)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvC is not raised!");
+			return evCValue;
+		}
+
+		private boolean evD;
+
+		private int evDValue;
+
+		public boolean isRaisedEvD() {
+			return evD;
+		}
+
+		private void raiseEvD(int value) {
+			evD = true;
+			evDValue = value;
+		}
+
+		public int getEvDValue() {
+			if (!evD)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvD is not raised!");
+			return evDValue;
+		}
+
+		private boolean evE;
+
+		private double evEValue;
+
+		public void raiseEvE(double value) {
+			evE = true;
+			evEValue = value;
+		}
+
+		private double getEvEValue() {
+			if (!evE)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvE is not raised!");
+			return evEValue;
+		}
+
+		private boolean evF;
+
+		private String evFValue;
+
+		public boolean isRaisedEvF() {
+			return evF;
+		}
+
+		private void raiseEvF(String value) {
+			evF = true;
+			evFValue = value;
+		}
+
+		public String getEvFValue() {
+			if (!evF)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvF is not raised!");
+			return evFValue;
+		}
+
+		private boolean varA = false;
+
+		public boolean getVarA() {
+			return varA;
+		}
+
+		public void setVarA(boolean value) {
+			this.varA = value;
+		}
+
+		private int varB = 1;
+
+		public int getVarB() {
+			return varB;
+		}
+
+		public void setVarB(int value) {
+			this.varB = value;
+		}
+
+		private double varC = 1.0;
+
+		public double getVarC() {
+			return varC;
+		}
+
+		public void setVarC(double value) {
+			this.varC = value;
+		}
+
+		private String varD = "myString";
+
+		public String getVarD() {
+			return varD;
+		}
+
+		public void setVarD(String value) {
+			this.varD = value;
+		}
+
+		public void clearEvents() {
+			evA = false;
+			evC = false;
+			evE = false;
+		}
+
+		public void clearOutEvents() {
+			evB = false;
+			evD = false;
+			evF = false;
+		}
+	}
+
+	private SCIDefaultImpl sCIDefault;
+	private final class SCIIfAImpl implements SCIIfA {
+
+		private boolean evA;
+
+		public void raiseEvA() {
+			evA = true;
+		}
+
+		private boolean evB;
+
+		public boolean isRaisedEvB() {
+			return evB;
+		}
+
+		private void raiseEvB() {
+			evB = true;
+		}
+
+		private boolean evC;
+
+		private boolean evCValue;
+
+		public void raiseEvC(boolean value) {
+			evC = true;
+			evCValue = value;
+		}
+
+		private boolean getEvCValue() {
+			if (!evC)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvC is not raised!");
+			return evCValue;
+		}
+
+		private boolean evD;
+
+		private int evDValue;
+
+		public boolean isRaisedEvD() {
+			return evD;
+		}
+
+		private void raiseEvD(int value) {
+			evD = true;
+			evDValue = value;
+		}
+
+		public int getEvDValue() {
+			if (!evD)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvD is not raised!");
+			return evDValue;
+		}
+
+		private boolean evE;
+
+		private double evEValue;
+
+		public void raiseEvE(double value) {
+			evE = true;
+			evEValue = value;
+		}
+
+		private double getEvEValue() {
+			if (!evE)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvE is not raised!");
+			return evEValue;
+		}
+
+		private boolean evF;
+
+		private String evFValue;
+
+		public boolean isRaisedEvF() {
+			return evF;
+		}
+
+		private void raiseEvF(String value) {
+			evF = true;
+			evFValue = value;
+		}
+
+		public String getEvFValue() {
+			if (!evF)
+				throw new IllegalStateException(
+						"Illegal event value acces. Event EvF is not raised!");
+			return evFValue;
+		}
+
+		private boolean varA = false;
+
+		public boolean getVarA() {
+			return varA;
+		}
+
+		public void setVarA(boolean value) {
+			this.varA = value;
+		}
+
+		private int varB = 1;
+
+		public int getVarB() {
+			return varB;
+		}
+
+		public void setVarB(int value) {
+			this.varB = value;
+		}
+
+		private double varC = 1.0;
+
+		public double getVarC() {
+			return varC;
+		}
+
+		public void setVarC(double value) {
+			this.varC = value;
+		}
+
+		private String varD = "myString";
+
+		public String getVarD() {
+			return varD;
+		}
+
+		public void setVarD(String value) {
+			this.varD = value;
+		}
+
+		public void clearEvents() {
+			evA = false;
+			evC = false;
+			evE = false;
+		}
+
+		public void clearOutEvents() {
+			evB = false;
+			evD = false;
+			evF = false;
+		}
+	}
+
+	private SCIIfAImpl sCIIfA;
+
+	public enum State {
+		main_region_A, $NullState$
+	};
+
+	private boolean varInA = false;
+	private int varInB = 1;
+	private double varInC = 1.0;
+	private String varInD = "myString";
+
+	private final State[] stateVector = new State[1];
+
+	private int nextStateIndex;
+
+	public DeclarationsStatemachine() {
+
+		sCIDefault = new SCIDefaultImpl();
+		sCIIfA = new SCIIfAImpl();
+
+	}
+
+	public void init() {
+		for (int i = 0; i < 1; i++) {
+			stateVector[i] = State.$NullState$;
+		}
+
+		clearEvents();
+		clearOutEvents();
+	}
+
+	public void enter() {
+		sCIDefault.varA = false;
+
+		sCIDefault.varB = 1;
+
+		sCIDefault.varC = 1.0;
+
+		sCIDefault.varD = "myString";
+
+		sCIIfA.varA = false;
+
+		sCIIfA.varB = 1;
+
+		sCIIfA.varC = 1.0;
+
+		sCIIfA.varD = "myString";
+
+		varInA = false;
+
+		varInB = 1;
+
+		varInC = 1.0;
+
+		varInD = "myString";
+
+		entryAction();
+
+		nextStateIndex = 0;
+		stateVector[0] = State.main_region_A;
+	}
+
+	public void exit() {
+		switch (stateVector[0]) {
+			case main_region_A :
+				nextStateIndex = 0;
+				stateVector[0] = State.$NullState$;
+				break;
+
+			default :
+				break;
+		}
+
+		exitAction();
+	}
+
+	protected void clearEvents() {
+		sCIDefault.clearEvents();
+		sCIIfA.clearEvents();
+		evInA = false;
+		evInB = false;
+		evInC = false;
+		evInD = false;
+		evInE = false;
+		evInF = false;
+
+	}
+
+	protected void clearOutEvents() {
+		sCIDefault.clearOutEvents();
+		sCIIfA.clearOutEvents();
+	}
+
+	public boolean isStateActive(State state) {
+		switch (state) {
+			case main_region_A :
+				return stateVector[0] == State.main_region_A;
+			default :
+				return false;
+		}
+	}
+
+	public SCIDefault getSCIDefault() {
+		return sCIDefault;
+	}
+	public SCIIfA getSCIIfA() {
+		return sCIIfA;
+	}
+
+	private void raiseEvInA() {
+		evInA = true;
+	}
+
+	private void raiseEvInB() {
+		evInB = true;
+	}
+
+	private void raiseEvInC(boolean value) {
+		evInCValue = value;
+		evInC = true;
+	}
+
+	private boolean getEvInCValue() {
+		if (!evInC)
+			throw new IllegalStateException(
+					"Illegal event value acces. Event EvInC is not raised!");
+		return evInCValue;
+	}
+	private void raiseEvInD(int value) {
+		evInDValue = value;
+		evInD = true;
+	}
+
+	private int getEvInDValue() {
+		if (!evInD)
+			throw new IllegalStateException(
+					"Illegal event value acces. Event EvInD is not raised!");
+		return evInDValue;
+	}
+	private void raiseEvInE(double value) {
+		evInEValue = value;
+		evInE = true;
+	}
+
+	private double getEvInEValue() {
+		if (!evInE)
+			throw new IllegalStateException(
+					"Illegal event value acces. Event EvInE is not raised!");
+		return evInEValue;
+	}
+	private void raiseEvInF(String value) {
+		evInFValue = value;
+		evInF = true;
+	}
+
+	private String getEvInFValue() {
+		if (!evInF)
+			throw new IllegalStateException(
+					"Illegal event value acces. Event EvInF is not raised!");
+		return evInFValue;
+	}
+	private boolean getVarInA() {
+		return varInA;
+	}
+
+	private void setVarInA(boolean value) {
+		varInA = value;
+	}
+	private int getVarInB() {
+		return varInB;
+	}
+
+	private void setVarInB(int value) {
+		varInB = value;
+	}
+	private double getVarInC() {
+		return varInC;
+	}
+
+	private void setVarInC(double value) {
+		varInC = value;
+	}
+	private String getVarInD() {
+		return varInD;
+	}
+
+	private void setVarInD(String value) {
+		varInD = value;
+	}
+
+	public void raiseEvA() {
+		sCIDefault.raiseEvA();
+	}
+	public boolean isRaisedEvB() {
+		return sCIDefault.isRaisedEvB();
+	}
+	public void raiseEvC(boolean value) {
+		sCIDefault.raiseEvC(value);
+	}
+	public boolean isRaisedEvD() {
+		return sCIDefault.isRaisedEvD();
+	}
+	public int getEvDValue() {
+		return sCIDefault.getEvDValue();
+	}
+	public void raiseEvE(double value) {
+		sCIDefault.raiseEvE(value);
+	}
+	public boolean isRaisedEvF() {
+		return sCIDefault.isRaisedEvF();
+	}
+	public String getEvFValue() {
+		return sCIDefault.getEvFValue();
+	}
+
+	public boolean getVarA() {
+		return sCIDefault.getVarA();
+	}
+
+	public void setVarA(boolean value) {
+		sCIDefault.setVarA(value);
+	}
+	public int getVarB() {
+		return sCIDefault.getVarB();
+	}
+
+	public void setVarB(int value) {
+		sCIDefault.setVarB(value);
+	}
+	public double getVarC() {
+		return sCIDefault.getVarC();
+	}
+
+	public void setVarC(double value) {
+		sCIDefault.setVarC(value);
+	}
+	public String getVarD() {
+		return sCIDefault.getVarD();
+	}
+
+	public void setVarD(String value) {
+		sCIDefault.setVarD(value);
+	}
+
+	/* Entry action for statechart 'Declarations'. */
+	private void entryAction() {
+	}
+
+	/* Exit action for state 'Declarations'. */
+	private void exitAction() {
+	}
+
+	/* The reactions of state A. */
+	private void reactMain_region_A() {
+	}
+
+	public void runCycle() {
+
+		clearOutEvents();
+
+		for (nextStateIndex = 0; nextStateIndex < stateVector.length; nextStateIndex++) {
+
+			switch (stateVector[nextStateIndex]) {
+				case main_region_A :
+					reactMain_region_A();
+					break;
+				default :
+					// $NullState$
+			}
+		}
+
+		clearEvents();
+	}
+}

+ 50 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/declarations/IDeclarationsStatemachine.java

@@ -0,0 +1,50 @@
+package org.yakindu.scr.declarations;
+import org.yakindu.scr.IStatemachine;
+
+public interface IDeclarationsStatemachine extends IStatemachine {
+
+	public interface SCIDefault {
+		public void raiseEvA();
+		public boolean isRaisedEvB();
+		public void raiseEvC(boolean value);
+		public boolean isRaisedEvD();
+		public int getEvDValue();
+		public void raiseEvE(double value);
+		public boolean isRaisedEvF();
+		public String getEvFValue();
+		public boolean getVarA();
+		public void setVarA(boolean value);
+		public int getVarB();
+		public void setVarB(int value);
+		public double getVarC();
+		public void setVarC(double value);
+		public String getVarD();
+		public void setVarD(String value);
+
+	}
+
+	public SCIDefault getSCIDefault();
+
+	public interface SCIIfA {
+		public void raiseEvA();
+		public boolean isRaisedEvB();
+		public void raiseEvC(boolean value);
+		public boolean isRaisedEvD();
+		public int getEvDValue();
+		public void raiseEvE(double value);
+		public boolean isRaisedEvF();
+		public String getEvFValue();
+		public boolean getVarA();
+		public void setVarA(boolean value);
+		public int getVarB();
+		public void setVarB(int value);
+		public double getVarC();
+		public void setVarC(double value);
+		public String getVarD();
+		public void setVarD(String value);
+
+	}
+
+	public SCIIfA getSCIIfA();
+
+}

+ 5 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/exitonselftransition/ExitOnSelfTransitionStatemachine.java

@@ -160,6 +160,11 @@ public class ExitOnSelfTransitionStatemachine
 	/* The reactions of state A. */
 	/* The reactions of state A. */
 	private void reactMain_region_A() {
 	private void reactMain_region_A() {
 		if (sCIDefault.e) {
 		if (sCIDefault.e) {
+			nextStateIndex = 0;
+			stateVector[0] = State.$NullState$;
+
+			sCIDefault.exitCount += 1;
+
 			sCIDefault.entryCount += 1;
 			sCIDefault.entryCount += 1;
 
 
 			nextStateIndex = 0;
 			nextStateIndex = 0;

+ 30 - 30
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AllTestsTest.java

@@ -1,30 +1,30 @@
-/**
- * Copyright (c) 2012 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.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-
-@RunWith(Suite.class)
-@SuiteClasses({AlwaysOncycleTest.class, AssignmentAsExpressionTest.class,
-		BitExpressionsTest.class, BooleanExpressionsTest.class,
-		CKeywordsTest.class, ChoiceTest.class, DeepHistoryTest.class,
-		ExitOnSelfTransitionTest.class, GuardTest.class,
-		GuardedEntryTest.class, GuardedExitTest.class,
-		IntegerExpressionsTest.class, InternalEventLifeCycleTest.class,
-		ParenthesisTest.class, PriorityValuesTest.class, RaiseEventTest.class,
-		SameNameDifferentRegionTest.class, ShallowHistoryTest.class,
-		SimpleHietachyTest.class, StateIsActiveTest.class,
-		StatechartLocalReactionsTest.class, StringExpressionsTest.class,
-		SyncForkTest.class, SyncJoinTest.class, ValuedEventTest.class,
-		SimpleEventTest.class})
-public class AllTestsTest {
-}
+/**
+ * Copyright (c) 2012 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.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+
+@RunWith(Suite.class)
+@SuiteClasses({AlwaysOncycleTest.class, AssignmentAsExpressionTest.class,
+		BitExpressionsTest.class, BooleanExpressionsTest.class,
+		CKeywordsTest.class, DeclarationsTest.class, ChoiceTest.class,
+		DeepHistoryTest.class, ExitOnSelfTransitionTest.class, GuardTest.class,
+		GuardedEntryTest.class, GuardedExitTest.class,
+		IntegerExpressionsTest.class, InternalEventLifeCycleTest.class,
+		ParenthesisTest.class, PriorityValuesTest.class, RaiseEventTest.class,
+		SameNameDifferentRegionTest.class, ShallowHistoryTest.class,
+		SimpleHietachyTest.class, StateIsActiveTest.class,
+		StatechartLocalReactionsTest.class, StringExpressionsTest.class,
+		SyncForkTest.class, SyncJoinTest.class, ValuedEventTest.class,
+		SimpleEventTest.class})
+public class AllTestsTest {
+}

+ 55 - 55
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AlwaysOncycleTest.java

@@ -1,55 +1,55 @@
-/**
- * Copyright (c) 2012 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.alwaysoncycle.AlwaysOncycleStatemachine;
-import org.yakindu.scr.alwaysoncycle.AlwaysOncycleStatemachine.State;
-/**
- *  Unit TestCase for AlwaysOncycle
- */
-@SuppressWarnings("all")
-public class AlwaysOncycleTest {
-
-	private AlwaysOncycleStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new AlwaysOncycleStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testalwaysOncycleTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		while (statemachine.getValue() < 5) {
-			statemachine.runCycle();
-			assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		}
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		while (statemachine.getValue() < 5) {
-			statemachine.runCycle();
-			assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		}
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-	}
-}
+/**
+ * Copyright (c) 2012 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.alwaysoncycle.AlwaysOncycleStatemachine;
+import org.yakindu.scr.alwaysoncycle.AlwaysOncycleStatemachine.State;
+/**
+ *  Unit TestCase for AlwaysOncycle
+ */
+@SuppressWarnings("all")
+public class AlwaysOncycleTest {
+
+	private AlwaysOncycleStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new AlwaysOncycleStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testalwaysOncycleTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		while (statemachine.getValue() < 5) {
+			statemachine.runCycle();
+			assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		}
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		while (statemachine.getValue() < 5) {
+			statemachine.runCycle();
+			assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		}
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+	}
+}

+ 45 - 45
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/AssignmentAsExpressionTest.java

@@ -1,45 +1,45 @@
-/**
- * Copyright (c) 2012 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.assignmentasexpression.AssignmentAsExpressionStatemachine;
-import org.yakindu.scr.assignmentasexpression.AssignmentAsExpressionStatemachine.State;
-/**
- *  Unit TestCase for AssignmentAsExpression
- */
-@SuppressWarnings("all")
-public class AssignmentAsExpressionTest {
-
-	private AssignmentAsExpressionStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new AssignmentAsExpressionStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsimpleAssignment() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getB() == 5);
-		assertTrue(statemachine.getA() == 9);
-	}
-}
+/**
+ * Copyright (c) 2012 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.assignmentasexpression.AssignmentAsExpressionStatemachine;
+import org.yakindu.scr.assignmentasexpression.AssignmentAsExpressionStatemachine.State;
+/**
+ *  Unit TestCase for AssignmentAsExpression
+ */
+@SuppressWarnings("all")
+public class AssignmentAsExpressionTest {
+
+	private AssignmentAsExpressionStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new AssignmentAsExpressionStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsimpleAssignment() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getB() == 5);
+		assertTrue(statemachine.getA() == 9);
+	}
+}

+ 54 - 54
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/BitExpressionsTest.java

@@ -1,54 +1,54 @@
-/**
- * Copyright (c) 2012 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.bitexpressions.BitExpressionsStatemachine;
-import org.yakindu.scr.bitexpressions.BitExpressionsStatemachine.State;
-/**
- *  Unit TestCase for BitExpressions
- */
-@SuppressWarnings("all")
-public class BitExpressionsTest {
-
-	private BitExpressionsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new BitExpressionsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testBitExpressions() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		assertTrue(statemachine.getMyBit1() == 5);
-		assertTrue(statemachine.getMyBit2() == 7);
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		assertTrue(statemachine.getLeftBitshift() == 10);
-		assertTrue(statemachine.getRightBitshift() == 2);
-		assertTrue(statemachine.getComplementBitshift() == -6);
-		assertTrue(statemachine.getBitwiseAnd() == 5);
-		assertTrue(statemachine.getBitwiseOr() == 7);
-		assertTrue(statemachine.getBitwiseXor() == 2);
-	}
-}
+/**
+ * Copyright (c) 2012 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.bitexpressions.BitExpressionsStatemachine;
+import org.yakindu.scr.bitexpressions.BitExpressionsStatemachine.State;
+/**
+ *  Unit TestCase for BitExpressions
+ */
+@SuppressWarnings("all")
+public class BitExpressionsTest {
+
+	private BitExpressionsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new BitExpressionsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testBitExpressions() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		assertTrue(statemachine.getMyBit1() == 5);
+		assertTrue(statemachine.getMyBit2() == 7);
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		assertTrue(statemachine.getLeftBitshift() == 10);
+		assertTrue(statemachine.getRightBitshift() == 2);
+		assertTrue(statemachine.getComplementBitshift() == -6);
+		assertTrue(statemachine.getBitwiseAnd() == 5);
+		assertTrue(statemachine.getBitwiseOr() == 7);
+		assertTrue(statemachine.getBitwiseXor() == 2);
+	}
+}

+ 53 - 53
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/BooleanExpressionsTest.java

@@ -1,53 +1,53 @@
-/**
- * Copyright (c) 2012 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.booleanexpressions.BooleanExpressionsStatemachine;
-import org.yakindu.scr.booleanexpressions.BooleanExpressionsStatemachine.State;
-/**
- *  Unit TestCase for BooleanExpressions
- */
-@SuppressWarnings("all")
-public class BooleanExpressionsTest {
-
-	private BooleanExpressionsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new BooleanExpressionsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testbooleanExpressions() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		assertTrue(statemachine.getMyBool1() == true);
-		assertTrue(statemachine.getMyBool2() == false);
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		assertTrue(statemachine.getAnd() == false);
-		assertTrue(statemachine.getOr() == true);
-		assertTrue(statemachine.getNot() == false);
-		assertTrue(statemachine.getEqual() == false);
-		assertTrue(statemachine.getNotequal() == true);
-	}
-}
+/**
+ * Copyright (c) 2012 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.booleanexpressions.BooleanExpressionsStatemachine;
+import org.yakindu.scr.booleanexpressions.BooleanExpressionsStatemachine.State;
+/**
+ *  Unit TestCase for BooleanExpressions
+ */
+@SuppressWarnings("all")
+public class BooleanExpressionsTest {
+
+	private BooleanExpressionsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new BooleanExpressionsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testbooleanExpressions() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		assertTrue(statemachine.getMyBool1() == true);
+		assertTrue(statemachine.getMyBool2() == false);
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		assertTrue(statemachine.getAnd() == false);
+		assertTrue(statemachine.getOr() == true);
+		assertTrue(statemachine.getNot() == false);
+		assertTrue(statemachine.getEqual() == false);
+		assertTrue(statemachine.getNotequal() == true);
+	}
+}

+ 49 - 49
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/CKeywordsTest.java

@@ -1,49 +1,49 @@
-/**
- * Copyright (c) 2012 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.ckeywords.CKeywordsStatemachine;
-import org.yakindu.scr.ckeywords.CKeywordsStatemachine.State;
-/**
- *  Unit TestCase for CKeywords
- */
-@SuppressWarnings("all")
-public class CKeywordsTest {
-
-	private CKeywordsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new CKeywordsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testCKeywordsTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.auto_char));
-		statemachine.raiseAuto();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.auto_const));
-		assertTrue(statemachine.isStateActive(State.auto_const_switch_case));
-		assertTrue(statemachine
-				.isStateActive(State.auto_const_switch_case_enum_asm));
-	}
-}
+/**
+ * Copyright (c) 2012 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.ckeywords.CKeywordsStatemachine;
+import org.yakindu.scr.ckeywords.CKeywordsStatemachine.State;
+/**
+ *  Unit TestCase for CKeywords
+ */
+@SuppressWarnings("all")
+public class CKeywordsTest {
+
+	private CKeywordsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new CKeywordsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testCKeywordsTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.auto_char));
+		statemachine.raiseAuto();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.auto_const));
+		assertTrue(statemachine.isStateActive(State.auto_const_switch_case));
+		assertTrue(statemachine
+				.isStateActive(State.auto_const_switch_case_enum_asm));
+	}
+}

+ 70 - 70
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ChoiceTest.java

@@ -1,70 +1,70 @@
-/**
- * Copyright (c) 2012 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.choice.ChoiceStatemachine;
-import org.yakindu.scr.choice.ChoiceStatemachine.State;
-/**
- *  Unit TestCase for Choice
- */
-@SuppressWarnings("all")
-public class ChoiceTest {
-
-	private ChoiceStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new ChoiceStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testchoiceTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getValue() == 4);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.getValue() == 3);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_C));
-		assertTrue(statemachine.getValue() == 2);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.getValue() == 1);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getValue() == 1);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_C));
-		assertTrue(statemachine.getValue() == 0);
-		statemachine.raisePressKey();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-	}
-}
+/**
+ * Copyright (c) 2012 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.choice.ChoiceStatemachine;
+import org.yakindu.scr.choice.ChoiceStatemachine.State;
+/**
+ *  Unit TestCase for Choice
+ */
+@SuppressWarnings("all")
+public class ChoiceTest {
+
+	private ChoiceStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new ChoiceStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testchoiceTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getValue() == 4);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.getValue() == 3);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_C));
+		assertTrue(statemachine.getValue() == 2);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.getValue() == 1);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getValue() == 1);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_C));
+		assertTrue(statemachine.getValue() == 0);
+		statemachine.raisePressKey();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+	}
+}

+ 42 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/DeclarationsTest.java

@@ -0,0 +1,42 @@
+/**
+ * Copyright (c) 2012 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.declarations.DeclarationsStatemachine;
+import org.yakindu.scr.declarations.DeclarationsStatemachine.State;
+/**
+ *  Unit TestCase for Declarations
+ */
+@SuppressWarnings("all")
+public class DeclarationsTest {
+
+	private DeclarationsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new DeclarationsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testdeclarationsTest() {
+		statemachine.enter();
+	}
+}

+ 63 - 63
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/DeepHistoryTest.java

@@ -1,63 +1,63 @@
-/**
- * Copyright (c) 2012 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.deephistory.DeepHistoryStatemachine;
-import org.yakindu.scr.deephistory.DeepHistoryStatemachine.State;
-/**
- *  Unit TestCase for DeepHistory
- */
-@SuppressWarnings("all")
-public class DeepHistoryTest {
-
-	private DeepHistoryStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new DeepHistoryStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testdeepHistoryTest() {
-		statemachine.enter();
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		statemachine.raiseEvent3();
-		statemachine.runCycle();
-		statemachine.raiseEvent5();
-		statemachine.runCycle();
-		statemachine.raiseEvent7();
-		statemachine.runCycle();
-		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		statemachine.raiseEvent2();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.mainRegion_State1));
-		assertTrue(!statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-	}
-}
+/**
+ * Copyright (c) 2012 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.deephistory.DeepHistoryStatemachine;
+import org.yakindu.scr.deephistory.DeepHistoryStatemachine.State;
+/**
+ *  Unit TestCase for DeepHistory
+ */
+@SuppressWarnings("all")
+public class DeepHistoryTest {
+
+	private DeepHistoryStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new DeepHistoryStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testdeepHistoryTest() {
+		statemachine.enter();
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		statemachine.raiseEvent3();
+		statemachine.runCycle();
+		statemachine.raiseEvent5();
+		statemachine.runCycle();
+		statemachine.raiseEvent7();
+		statemachine.runCycle();
+		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		statemachine.raiseEvent2();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.mainRegion_State1));
+		assertTrue(!statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+	}
+}

+ 53 - 53
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ExitOnSelfTransitionTest.java

@@ -1,53 +1,53 @@
-/**
- * Copyright (c) 2012 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.exitonselftransition.ExitOnSelfTransitionStatemachine;
-import org.yakindu.scr.exitonselftransition.ExitOnSelfTransitionStatemachine.State;
-/**
- *  Unit TestCase for ExitOnSelfTransition
- */
-@SuppressWarnings("all")
-public class ExitOnSelfTransitionTest {
-
-	private ExitOnSelfTransitionStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new ExitOnSelfTransitionStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testExitOnSelfTransitionTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getEntryCount() == 1);
-		assertTrue(statemachine.getExitCount() == 0);
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.getEntryCount() == 2);
-		assertTrue(statemachine.getExitCount() == 1);
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.getEntryCount() == 2);
-		assertTrue(statemachine.getExitCount() == 2);
-	}
-}
+/**
+ * Copyright (c) 2012 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.exitonselftransition.ExitOnSelfTransitionStatemachine;
+import org.yakindu.scr.exitonselftransition.ExitOnSelfTransitionStatemachine.State;
+/**
+ *  Unit TestCase for ExitOnSelfTransition
+ */
+@SuppressWarnings("all")
+public class ExitOnSelfTransitionTest {
+
+	private ExitOnSelfTransitionStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new ExitOnSelfTransitionStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testExitOnSelfTransitionTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getEntryCount() == 1);
+		assertTrue(statemachine.getExitCount() == 0);
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.getEntryCount() == 2);
+		assertTrue(statemachine.getExitCount() == 1);
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.getEntryCount() == 2);
+		assertTrue(statemachine.getExitCount() == 2);
+	}
+}

+ 45 - 45
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/FeatureCallsTest.java

@@ -1,45 +1,45 @@
-/**
- * Copyright (c) 2012 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.featurecalls.FeatureCallsStatemachine;
-import org.yakindu.scr.featurecalls.FeatureCallsStatemachine.State;
-/**
- *  Unit TestCase for FeatureCalls
- */
-@SuppressWarnings("all")
-public class FeatureCallsTest {
-
-	private FeatureCallsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new FeatureCallsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testFeatureCalls() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-	}
-}
+/**
+ * Copyright (c) 2012 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.featurecalls.FeatureCallsStatemachine;
+import org.yakindu.scr.featurecalls.FeatureCallsStatemachine.State;
+/**
+ *  Unit TestCase for FeatureCalls
+ */
+@SuppressWarnings("all")
+public class FeatureCallsTest {
+
+	private FeatureCallsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new FeatureCallsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testFeatureCalls() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+	}
+}

+ 58 - 58
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardTest.java

@@ -1,58 +1,58 @@
-/**
- * Copyright (c) 2012 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.guard.GuardStatemachine;
-import org.yakindu.scr.guard.GuardStatemachine.State;
-/**
- *  Unit TestCase for Guard
- */
-@SuppressWarnings("all")
-public class GuardTest {
-
-	private GuardStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new GuardStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testguardTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseEvent2();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		statemachine.raiseReturn();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		statemachine.raiseReturn();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-	}
-}
+/**
+ * Copyright (c) 2012 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.guard.GuardStatemachine;
+import org.yakindu.scr.guard.GuardStatemachine.State;
+/**
+ *  Unit TestCase for Guard
+ */
+@SuppressWarnings("all")
+public class GuardTest {
+
+	private GuardStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new GuardStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testguardTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseEvent2();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		statemachine.raiseReturn();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		statemachine.raiseReturn();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+	}
+}

+ 82 - 82
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardedEntryTest.java

@@ -1,82 +1,82 @@
-/**
- * Copyright (c) 2012 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.guardedentry.GuardedEntryStatemachine;
-import org.yakindu.scr.guardedentry.GuardedEntryStatemachine.State;
-/**
- *  Unit TestCase for GuardedEntry
- */
-@SuppressWarnings("all")
-public class GuardedEntryTest {
-
-	private GuardedEntryStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new GuardedEntryStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testEntryNotTakenOnStatechartEnter() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getDone() == false);
-	}
-	@Test
-	public void testEntryTakenOnStatechartEnter() {
-		statemachine.enter();
-		statemachine.setGuard(true);
-		assertTrue(
-				"sctunit does not allow modifiing variables before entering the state machine!",
-				false);
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getDone() == true);
-	}
-	@Test
-	public void testEntryTakenInTransition() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		statemachine.setGuard(true);
-		statemachine.setDone(false);
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.getDone());
-	}
-	@Test
-	public void testEntryNotTakenInTransition() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		statemachine.setGuard(false);
-		statemachine.setDone(false);
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(!statemachine.getDone());
-	}
-}
+/**
+ * Copyright (c) 2012 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.guardedentry.GuardedEntryStatemachine;
+import org.yakindu.scr.guardedentry.GuardedEntryStatemachine.State;
+/**
+ *  Unit TestCase for GuardedEntry
+ */
+@SuppressWarnings("all")
+public class GuardedEntryTest {
+
+	private GuardedEntryStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new GuardedEntryStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testEntryNotTakenOnStatechartEnter() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getDone() == false);
+	}
+	@Test
+	public void testEntryTakenOnStatechartEnter() {
+		statemachine.enter();
+		statemachine.setGuard(true);
+		assertTrue(
+				"sctunit does not allow modifiing variables before entering the state machine!",
+				false);
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getDone() == true);
+	}
+	@Test
+	public void testEntryTakenInTransition() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		statemachine.setGuard(true);
+		statemachine.setDone(false);
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.getDone());
+	}
+	@Test
+	public void testEntryNotTakenInTransition() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		statemachine.setGuard(false);
+		statemachine.setDone(false);
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(!statemachine.getDone());
+	}
+}

+ 58 - 58
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/GuardedExitTest.java

@@ -1,58 +1,58 @@
-/**
- * Copyright (c) 2012 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.guardedexit.GuardedExitStatemachine;
-import org.yakindu.scr.guardedexit.GuardedExitStatemachine.State;
-/**
- *  Unit TestCase for GuardedExit
- */
-@SuppressWarnings("all")
-public class GuardedExitTest {
-
-	private GuardedExitStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new GuardedExitStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testExitTaken() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(!statemachine.getGuard());
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(!statemachine.getDone());
-	}
-	@Test
-	public void testExitNotTaken() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.setGuard(true);
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.getDone());
-	}
-}
+/**
+ * Copyright (c) 2012 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.guardedexit.GuardedExitStatemachine;
+import org.yakindu.scr.guardedexit.GuardedExitStatemachine.State;
+/**
+ *  Unit TestCase for GuardedExit
+ */
+@SuppressWarnings("all")
+public class GuardedExitTest {
+
+	private GuardedExitStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new GuardedExitStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testExitTaken() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(!statemachine.getGuard());
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(!statemachine.getDone());
+	}
+	@Test
+	public void testExitNotTaken() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.setGuard(true);
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.getDone());
+	}
+}

+ 64 - 64
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/IntegerExpressionsTest.java

@@ -1,64 +1,64 @@
-/**
- * Copyright (c) 2012 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.integerexpressions.IntegerExpressionsStatemachine;
-import org.yakindu.scr.integerexpressions.IntegerExpressionsStatemachine.State;
-/**
- *  Unit TestCase for IntegerExpressions
- */
-@SuppressWarnings("all")
-public class IntegerExpressionsTest {
-
-	private IntegerExpressionsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new IntegerExpressionsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testintegerExpressions() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		assertTrue(statemachine.getMyInt1() == 10);
-		assertTrue(statemachine.getMyInt2() == 5);
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.getLess() == false);
-		assertTrue(statemachine.getGreater() == true);
-		assertTrue(statemachine.getEqualOrLess() == false);
-		assertTrue(statemachine.getEqualOrGreater() == true);
-		assertTrue(statemachine.getEqual() == false);
-		assertTrue(statemachine.getNotEqual() == true);
-		assertTrue(statemachine.getPlus() == 15);
-		assertTrue(statemachine.getMinus() == 5);
-		assertTrue(statemachine.getMultiply() == 50);
-		assertTrue(statemachine.getDivision() == 2);
-		assertTrue(statemachine.getModulo() == 0);
-		assertTrue(statemachine.getNegat() == -10);
-		assertTrue(statemachine.getMultiAssign() == 20);
-		assertTrue(statemachine.getDivAssign() == 2);
-		assertTrue(statemachine.getPlusAssign() == 12);
-		assertTrue(statemachine.getMinusAssign() == -8);
-		assertTrue(statemachine.getModuloAssign() == 0);
-	}
-}
+/**
+ * Copyright (c) 2012 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.integerexpressions.IntegerExpressionsStatemachine;
+import org.yakindu.scr.integerexpressions.IntegerExpressionsStatemachine.State;
+/**
+ *  Unit TestCase for IntegerExpressions
+ */
+@SuppressWarnings("all")
+public class IntegerExpressionsTest {
+
+	private IntegerExpressionsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new IntegerExpressionsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testintegerExpressions() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		assertTrue(statemachine.getMyInt1() == 10);
+		assertTrue(statemachine.getMyInt2() == 5);
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.getLess() == false);
+		assertTrue(statemachine.getGreater() == true);
+		assertTrue(statemachine.getEqualOrLess() == false);
+		assertTrue(statemachine.getEqualOrGreater() == true);
+		assertTrue(statemachine.getEqual() == false);
+		assertTrue(statemachine.getNotEqual() == true);
+		assertTrue(statemachine.getPlus() == 15);
+		assertTrue(statemachine.getMinus() == 5);
+		assertTrue(statemachine.getMultiply() == 50);
+		assertTrue(statemachine.getDivision() == 2);
+		assertTrue(statemachine.getModulo() == 0);
+		assertTrue(statemachine.getNegat() == -10);
+		assertTrue(statemachine.getMultiAssign() == 20);
+		assertTrue(statemachine.getDivAssign() == 2);
+		assertTrue(statemachine.getPlusAssign() == 12);
+		assertTrue(statemachine.getMinusAssign() == -8);
+		assertTrue(statemachine.getModuloAssign() == 0);
+	}
+}

+ 58 - 58
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/InternalEventLifeCycleTest.java

@@ -1,58 +1,58 @@
-/**
- * Copyright (c) 2012 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.internaleventlifecycle.InternalEventLifeCycleStatemachine;
-import org.yakindu.scr.internaleventlifecycle.InternalEventLifeCycleStatemachine.State;
-/**
- *  Unit TestCase for InternalEventLifeCycle
- */
-@SuppressWarnings("all")
-public class InternalEventLifeCycleTest {
-
-	private InternalEventLifeCycleStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new InternalEventLifeCycleStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testInternalEventLifeCycleTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.r1_A));
-		assertTrue(statemachine.isStateActive(State.r2_C));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.r1_A));
-		assertTrue(statemachine.isStateActive(State.r2_D));
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.r1_A));
-		assertTrue(statemachine.isStateActive(State.r2_D));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.r1_A));
-		assertTrue(statemachine.isStateActive(State.r2_C));
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.r1_A));
-		assertTrue(statemachine.isStateActive(State.r2_C));
-	}
-}
+/**
+ * Copyright (c) 2012 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.internaleventlifecycle.InternalEventLifeCycleStatemachine;
+import org.yakindu.scr.internaleventlifecycle.InternalEventLifeCycleStatemachine.State;
+/**
+ *  Unit TestCase for InternalEventLifeCycle
+ */
+@SuppressWarnings("all")
+public class InternalEventLifeCycleTest {
+
+	private InternalEventLifeCycleStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new InternalEventLifeCycleStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testInternalEventLifeCycleTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.r1_A));
+		assertTrue(statemachine.isStateActive(State.r2_C));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.r1_A));
+		assertTrue(statemachine.isStateActive(State.r2_D));
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.r1_A));
+		assertTrue(statemachine.isStateActive(State.r2_D));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.r1_A));
+		assertTrue(statemachine.isStateActive(State.r2_C));
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.r1_A));
+		assertTrue(statemachine.isStateActive(State.r2_C));
+	}
+}

+ 44 - 44
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ParenthesisTest.java

@@ -1,44 +1,44 @@
-/**
- * Copyright (c) 2012 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.parenthesis.ParenthesisStatemachine;
-import org.yakindu.scr.parenthesis.ParenthesisStatemachine.State;
-/**
- *  Unit TestCase for Parenthesis
- */
-@SuppressWarnings("all")
-public class ParenthesisTest {
-
-	private ParenthesisStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new ParenthesisStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsimple() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.mainRegion_A));
-		assertTrue(statemachine.getErg() == 8);
-	}
-}
+/**
+ * Copyright (c) 2012 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.parenthesis.ParenthesisStatemachine;
+import org.yakindu.scr.parenthesis.ParenthesisStatemachine.State;
+/**
+ *  Unit TestCase for Parenthesis
+ */
+@SuppressWarnings("all")
+public class ParenthesisTest {
+
+	private ParenthesisStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new ParenthesisStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsimple() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.mainRegion_A));
+		assertTrue(statemachine.getErg() == 8);
+	}
+}

+ 92 - 92
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/PerformanceTestsTest.java

@@ -1,92 +1,92 @@
-/**
- * Copyright (c) 2012 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.performancetest.PerformanceTestStatemachine;
-import org.yakindu.scr.performancetest.PerformanceTestStatemachine.State;
-/**
- *  Unit TestCase for PerformanceTest
- */
-@SuppressWarnings("all")
-public class PerformanceTestsTest {
-
-	private PerformanceTestStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new PerformanceTestStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testtest_100_000() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.mr_A));
-		while (statemachine.getC() < 100000) {
-			if (statemachine.isStateActive(State.mr_A)) {
-				statemachine.raiseE1();;
-			} else {
-				if (statemachine.getC() % 2 == 0) {
-					statemachine.raiseE2();;
-				} else {
-					statemachine.raiseE3();;
-				};
-			}
-			statemachine.runCycle();
-		}
-		assertTrue(statemachine.getA() > 2);
-	}
-	@Test
-	public void testtest_1_000_000() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.mr_A));
-		while (statemachine.getC() < 1000000) {
-			if (statemachine.isStateActive(State.mr_A)) {
-				statemachine.raiseE1();;
-			} else {
-				if (statemachine.getC() % 2 == 0) {
-					statemachine.raiseE2();;
-				} else {
-					statemachine.raiseE3();;
-				};
-			}
-			statemachine.runCycle();
-		}
-		assertTrue(statemachine.getA() > 2);
-	}
-	@Test
-	public void testtest_10_000_000() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.mr_A));
-		while (statemachine.getC() < 10000000) {
-			if (statemachine.isStateActive(State.mr_A)) {
-				statemachine.raiseE1();;
-			} else {
-				if (statemachine.getC() % 2 == 0) {
-					statemachine.raiseE2();;
-				} else {
-					statemachine.raiseE3();;
-				};
-			}
-			statemachine.runCycle();
-		}
-		assertTrue(statemachine.getA() > 2);
-	}
-}
+/**
+ * Copyright (c) 2012 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.performancetest.PerformanceTestStatemachine;
+import org.yakindu.scr.performancetest.PerformanceTestStatemachine.State;
+/**
+ *  Unit TestCase for PerformanceTest
+ */
+@SuppressWarnings("all")
+public class PerformanceTestsTest {
+
+	private PerformanceTestStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new PerformanceTestStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testtest_100_000() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.mr_A));
+		while (statemachine.getC() < 100000) {
+			if (statemachine.isStateActive(State.mr_A)) {
+				statemachine.raiseE1();;
+			} else {
+				if (statemachine.getC() % 2 == 0) {
+					statemachine.raiseE2();;
+				} else {
+					statemachine.raiseE3();;
+				};
+			}
+			statemachine.runCycle();
+		}
+		assertTrue(statemachine.getA() > 2);
+	}
+	@Test
+	public void testtest_1_000_000() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.mr_A));
+		while (statemachine.getC() < 1000000) {
+			if (statemachine.isStateActive(State.mr_A)) {
+				statemachine.raiseE1();;
+			} else {
+				if (statemachine.getC() % 2 == 0) {
+					statemachine.raiseE2();;
+				} else {
+					statemachine.raiseE3();;
+				};
+			}
+			statemachine.runCycle();
+		}
+		assertTrue(statemachine.getA() > 2);
+	}
+	@Test
+	public void testtest_10_000_000() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.mr_A));
+		while (statemachine.getC() < 10000000) {
+			if (statemachine.isStateActive(State.mr_A)) {
+				statemachine.raiseE1();;
+			} else {
+				if (statemachine.getC() % 2 == 0) {
+					statemachine.raiseE2();;
+				} else {
+					statemachine.raiseE3();;
+				};
+			}
+			statemachine.runCycle();
+		}
+		assertTrue(statemachine.getA() > 2);
+	}
+}

+ 55 - 55
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/PriorityValuesTest.java

@@ -1,55 +1,55 @@
-/**
- * Copyright (c) 2012 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.priorityvalues.PriorityValuesStatemachine;
-import org.yakindu.scr.priorityvalues.PriorityValuesStatemachine.State;
-/**
- *  Unit TestCase for PriorityValues
- */
-@SuppressWarnings("all")
-public class PriorityValuesTest {
-
-	private PriorityValuesStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new PriorityValuesStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testtransitionPriority() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_C));
-	}
-	@Test
-	public void testregionPriority() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.someRegion_A));
-		statemachine.raiseEvent2();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.someRegion_B));
-		assertTrue(!statemachine.isStateActive(State.main_region_E));
-	}
-}
+/**
+ * Copyright (c) 2012 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.priorityvalues.PriorityValuesStatemachine;
+import org.yakindu.scr.priorityvalues.PriorityValuesStatemachine.State;
+/**
+ *  Unit TestCase for PriorityValues
+ */
+@SuppressWarnings("all")
+public class PriorityValuesTest {
+
+	private PriorityValuesStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new PriorityValuesStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testtransitionPriority() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_C));
+	}
+	@Test
+	public void testregionPriority() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.someRegion_A));
+		statemachine.raiseEvent2();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.someRegion_B));
+		assertTrue(!statemachine.isStateActive(State.main_region_E));
+	}
+}

+ 49 - 49
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/RaiseEventTest.java

@@ -1,49 +1,49 @@
-/**
- * Copyright (c) 2012 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.raiseevent.RaiseEventStatemachine;
-import org.yakindu.scr.raiseevent.RaiseEventStatemachine.State;
-/**
- *  Unit TestCase for RaiseEvent
- */
-@SuppressWarnings("all")
-public class RaiseEventTest {
-
-	private RaiseEventStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new RaiseEventStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testraiseEvent() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.second_region_SateA));
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		statemachine.raiseE2();
-		statemachine.runCycle();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.second_region_StateB));
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-	}
-}
+/**
+ * Copyright (c) 2012 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.raiseevent.RaiseEventStatemachine;
+import org.yakindu.scr.raiseevent.RaiseEventStatemachine.State;
+/**
+ *  Unit TestCase for RaiseEvent
+ */
+@SuppressWarnings("all")
+public class RaiseEventTest {
+
+	private RaiseEventStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new RaiseEventStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testraiseEvent() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.second_region_SateA));
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		statemachine.raiseE2();
+		statemachine.runCycle();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.second_region_StateB));
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+	}
+}

+ 53 - 53
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SameNameDifferentRegionTest.java

@@ -1,53 +1,53 @@
-/**
- * Copyright (c) 2012 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.samenamedifferentregion.SameNameDifferentRegionStatemachine;
-import org.yakindu.scr.samenamedifferentregion.SameNameDifferentRegionStatemachine.State;
-/**
- *  Unit TestCase for SameNameDifferentRegion
- */
-@SuppressWarnings("all")
-public class SameNameDifferentRegionTest {
-
-	private SameNameDifferentRegionStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new SameNameDifferentRegionStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsameNameDifferenRegionTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		assertTrue(statemachine
-				.isStateActive(State.main_region_StateB_r1_StateA));
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		assertTrue(statemachine
-				.isStateActive(State.main_region_StateB_r1_StateB));
-	}
-}
+/**
+ * Copyright (c) 2012 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.samenamedifferentregion.SameNameDifferentRegionStatemachine;
+import org.yakindu.scr.samenamedifferentregion.SameNameDifferentRegionStatemachine.State;
+/**
+ *  Unit TestCase for SameNameDifferentRegion
+ */
+@SuppressWarnings("all")
+public class SameNameDifferentRegionTest {
+
+	private SameNameDifferentRegionStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new SameNameDifferentRegionStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsameNameDifferenRegionTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		assertTrue(statemachine
+				.isStateActive(State.main_region_StateB_r1_StateA));
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		assertTrue(statemachine
+				.isStateActive(State.main_region_StateB_r1_StateB));
+	}
+}

+ 81 - 81
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ShallowHistoryTest.java

@@ -1,81 +1,81 @@
-/**
- * Copyright (c) 2012 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.shallowhistory.ShallowHistoryStatemachine;
-import org.yakindu.scr.shallowhistory.ShallowHistoryStatemachine.State;
-/**
- *  Unit TestCase for ShallowHistory
- */
-@SuppressWarnings("all")
-public class ShallowHistoryTest {
-
-	private ShallowHistoryStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new ShallowHistoryStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testshallowHistoryTest() {
-		statemachine.enter();
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		statemachine.raiseEvent3();
-		statemachine.runCycle();
-		statemachine.raiseEvent5();
-		statemachine.runCycle();
-		statemachine.raiseEvent7();
-		statemachine.runCycle();
-		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		statemachine.raiseEvent6();
-		statemachine.runCycle();
-		assertTrue(!statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
-		statemachine.raiseEvent5();
-		statemachine.runCycle();
-		assertTrue(!statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State8));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		statemachine.raiseEvent2();
-		statemachine.runCycle();
-		assertTrue(!statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-		assertTrue(statemachine.isStateActive(State.mainRegion_State1));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
-		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
-		statemachine.raiseEvent5();
-		statemachine.runCycle();
-		assertTrue(!statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
-		assertTrue(statemachine
-				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
-	}
-}
+/**
+ * Copyright (c) 2012 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.shallowhistory.ShallowHistoryStatemachine;
+import org.yakindu.scr.shallowhistory.ShallowHistoryStatemachine.State;
+/**
+ *  Unit TestCase for ShallowHistory
+ */
+@SuppressWarnings("all")
+public class ShallowHistoryTest {
+
+	private ShallowHistoryStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new ShallowHistoryStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testshallowHistoryTest() {
+		statemachine.enter();
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		statemachine.raiseEvent3();
+		statemachine.runCycle();
+		statemachine.raiseEvent5();
+		statemachine.runCycle();
+		statemachine.raiseEvent7();
+		statemachine.runCycle();
+		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		statemachine.raiseEvent6();
+		statemachine.runCycle();
+		assertTrue(!statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
+		statemachine.raiseEvent5();
+		statemachine.runCycle();
+		assertTrue(!statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State8));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		statemachine.raiseEvent2();
+		statemachine.runCycle();
+		assertTrue(!statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+		assertTrue(statemachine.isStateActive(State.mainRegion_State1));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
+		assertTrue(!statemachine.isStateActive(State.mainRegion_State1));
+		statemachine.raiseEvent5();
+		statemachine.runCycle();
+		assertTrue(!statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State6));
+		assertTrue(statemachine
+				.isStateActive(State.mainRegion_State2__region0_State4__region0_State7__region0_State9));
+	}
+}

+ 49 - 49
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SimpleEventTest.java

@@ -1,49 +1,49 @@
-/**
- * Copyright (c) 2012 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.simpleevent.SimpleEventStatemachine;
-import org.yakindu.scr.simpleevent.SimpleEventStatemachine.State;
-/**
- *  Unit TestCase for SimpleEvent
- */
-@SuppressWarnings("all")
-public class SimpleEventTest {
-
-	private SimpleEventStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new SimpleEventStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsimpleEventTest() {
-		statemachine.enter();
-		assertTrue("Expected A to be active",
-				statemachine.isStateActive(State.main_region_A));
-		assertTrue(5 == 5);
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue("Expected B to be active",
-				statemachine.isStateActive(State.main_region_B));
-	}
-}
+/**
+ * Copyright (c) 2012 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.simpleevent.SimpleEventStatemachine;
+import org.yakindu.scr.simpleevent.SimpleEventStatemachine.State;
+/**
+ *  Unit TestCase for SimpleEvent
+ */
+@SuppressWarnings("all")
+public class SimpleEventTest {
+
+	private SimpleEventStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new SimpleEventStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsimpleEventTest() {
+		statemachine.enter();
+		assertTrue("Expected A to be active",
+				statemachine.isStateActive(State.main_region_A));
+		assertTrue(5 == 5);
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue("Expected B to be active",
+				statemachine.isStateActive(State.main_region_B));
+	}
+}

+ 50 - 50
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SimpleHietachyTest.java

@@ -1,50 +1,50 @@
-/**
- * Copyright (c) 2012 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.simplehierachy.SimpleHierachyStatemachine;
-import org.yakindu.scr.simplehierachy.SimpleHierachyStatemachine.State;
-/**
- *  Unit TestCase for SimpleHierachy
- */
-@SuppressWarnings("all")
-public class SimpleHietachyTest {
-
-	private SimpleHierachyStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new SimpleHierachyStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsimpleHierachyTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseEvent1();
-		statemachine.raiseEvent1();
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine
-				.isStateActive(State.main_region_B_subregion1_B1));
-	}
-}
+/**
+ * Copyright (c) 2012 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.simplehierachy.SimpleHierachyStatemachine;
+import org.yakindu.scr.simplehierachy.SimpleHierachyStatemachine.State;
+/**
+ *  Unit TestCase for SimpleHierachy
+ */
+@SuppressWarnings("all")
+public class SimpleHietachyTest {
+
+	private SimpleHierachyStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new SimpleHierachyStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsimpleHierachyTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseEvent1();
+		statemachine.raiseEvent1();
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine
+				.isStateActive(State.main_region_B_subregion1_B1));
+	}
+}

+ 49 - 49
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StateIsActiveTest.java

@@ -1,49 +1,49 @@
-/**
- * Copyright (c) 2012 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.stateisactive.StateIsActiveStatemachine;
-import org.yakindu.scr.stateisactive.StateIsActiveStatemachine.State;
-/**
- *  Unit TestCase for StateIsActive
- */
-@SuppressWarnings("all")
-public class StateIsActiveTest {
-
-	private StateIsActiveStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new StateIsActiveStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void teststateIsActive() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.r1_R1A));
-		assertTrue(statemachine.isStateActive(State.r2_R2A));
-		statemachine.raiseEvent1();
-		statemachine.runCycle();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.r1_R1B));
-		assertTrue(statemachine.isStateActive(State.r2_R2B));
-	}
-}
+/**
+ * Copyright (c) 2012 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.stateisactive.StateIsActiveStatemachine;
+import org.yakindu.scr.stateisactive.StateIsActiveStatemachine.State;
+/**
+ *  Unit TestCase for StateIsActive
+ */
+@SuppressWarnings("all")
+public class StateIsActiveTest {
+
+	private StateIsActiveStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new StateIsActiveStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void teststateIsActive() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.r1_R1A));
+		assertTrue(statemachine.isStateActive(State.r2_R2A));
+		statemachine.raiseEvent1();
+		statemachine.runCycle();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.r1_R1B));
+		assertTrue(statemachine.isStateActive(State.r2_R2B));
+	}
+}

+ 53 - 53
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StatechartLocalReactionsTest.java

@@ -1,53 +1,53 @@
-/**
- * Copyright (c) 2012 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.statechartlocalreactions.StatechartLocalReactionsStatemachine;
-import org.yakindu.scr.statechartlocalreactions.StatechartLocalReactionsStatemachine.State;
-/**
- *  Unit TestCase for StatechartLocalReactions
- */
-@SuppressWarnings("all")
-public class StatechartLocalReactionsTest {
-
-	private StatechartLocalReactionsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new StatechartLocalReactionsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void teststatechartLocalReactionsTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_S1));
-		assertTrue(statemachine.isStateActive(State.region2_a));
-		while (statemachine.getMyInt() < 10) {
-			assertTrue(statemachine.isStateActive(State.region2_a));
-			if (statemachine.getMyInt() % 2 == 0) {
-				assertTrue(statemachine.isStateActive(State.main_region_S1));;
-			} else {
-				assertTrue(statemachine.isStateActive(State.main_region_S2));;
-			}
-			statemachine.runCycle();
-		}
-	}
-}
+/**
+ * Copyright (c) 2012 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.statechartlocalreactions.StatechartLocalReactionsStatemachine;
+import org.yakindu.scr.statechartlocalreactions.StatechartLocalReactionsStatemachine.State;
+/**
+ *  Unit TestCase for StatechartLocalReactions
+ */
+@SuppressWarnings("all")
+public class StatechartLocalReactionsTest {
+
+	private StatechartLocalReactionsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new StatechartLocalReactionsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void teststatechartLocalReactionsTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_S1));
+		assertTrue(statemachine.isStateActive(State.region2_a));
+		while (statemachine.getMyInt() < 10) {
+			assertTrue(statemachine.isStateActive(State.region2_a));
+			if (statemachine.getMyInt() % 2 == 0) {
+				assertTrue(statemachine.isStateActive(State.main_region_S1));;
+			} else {
+				assertTrue(statemachine.isStateActive(State.main_region_S2));;
+			}
+			statemachine.runCycle();
+		}
+	}
+}

+ 50 - 50
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/StringExpressionsTest.java

@@ -1,50 +1,50 @@
-/**
- * Copyright (c) 2012 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.stringexpressions.StringExpressionsStatemachine;
-import org.yakindu.scr.stringexpressions.StringExpressionsStatemachine.State;
-/**
- *  Unit TestCase for StringExpressions
- */
-@SuppressWarnings("all")
-public class StringExpressionsTest {
-
-	private StringExpressionsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new StringExpressionsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testStringExpressionsTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_StateA));
-		assertTrue(statemachine.getMyString().equals("hello"));
-		assertTrue(statemachine.getMyString2().equals("world"));
-		statemachine.raiseE1();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_StateB));
-		assertTrue(statemachine.getEquals() == false);
-		assertTrue(statemachine.getNotEqual() == true);
-	}
-}
+/**
+ * Copyright (c) 2012 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.stringexpressions.StringExpressionsStatemachine;
+import org.yakindu.scr.stringexpressions.StringExpressionsStatemachine.State;
+/**
+ *  Unit TestCase for StringExpressions
+ */
+@SuppressWarnings("all")
+public class StringExpressionsTest {
+
+	private StringExpressionsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new StringExpressionsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testStringExpressionsTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_StateA));
+		assertTrue(statemachine.getMyString().equals("hello"));
+		assertTrue(statemachine.getMyString2().equals("world"));
+		statemachine.raiseE1();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_StateB));
+		assertTrue(statemachine.getEquals() == false);
+		assertTrue(statemachine.getNotEqual() == true);
+	}
+}

+ 61 - 61
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SyncForkTest.java

@@ -1,61 +1,61 @@
-/**
- * Copyright (c) 2012 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.syncfork.SyncForkStatemachine;
-import org.yakindu.scr.syncfork.SyncForkStatemachine.State;
-/**
- *  Unit TestCase for SyncFork
- */
-@SuppressWarnings("all")
-public class SyncForkTest {
-
-	private SyncForkStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new SyncForkStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsyncForkTest() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-	}
-}
+/**
+ * Copyright (c) 2012 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.syncfork.SyncForkStatemachine;
+import org.yakindu.scr.syncfork.SyncForkStatemachine.State;
+/**
+ *  Unit TestCase for SyncFork
+ */
+@SuppressWarnings("all")
+public class SyncForkTest {
+
+	private SyncForkStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new SyncForkStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsyncForkTest() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+	}
+}

+ 106 - 106
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/SyncJoinTest.java

@@ -1,106 +1,106 @@
-/**
- * Copyright (c) 2012 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.syncjoin.SyncJoinStatemachine;
-import org.yakindu.scr.syncjoin.SyncJoinStatemachine.State;
-/**
- *  Unit TestCase for SyncJoin
- */
-@SuppressWarnings("all")
-public class SyncJoinTest {
-
-	private SyncJoinStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new SyncJoinStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testsyncJoin_C2_Waits() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseJc();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseJc();
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJc();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJc();
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-	}
-	@Test
-	public void testsyncJoin_D2_Waits() {
-		statemachine.enter();
-		assertTrue(statemachine.isStateActive(State.main_region_B));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
-		statemachine.raiseF();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJc();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseJc();
-		statemachine.raiseJd();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-		statemachine.raiseE();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
-		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
-	}
-}
+/**
+ * Copyright (c) 2012 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.syncjoin.SyncJoinStatemachine;
+import org.yakindu.scr.syncjoin.SyncJoinStatemachine.State;
+/**
+ *  Unit TestCase for SyncJoin
+ */
+@SuppressWarnings("all")
+public class SyncJoinTest {
+
+	private SyncJoinStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new SyncJoinStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testsyncJoin_C2_Waits() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseJc();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseJc();
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJc();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJc();
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+	}
+	@Test
+	public void testsyncJoin_D2_Waits() {
+		statemachine.enter();
+		assertTrue(statemachine.isStateActive(State.main_region_B));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D1));
+		statemachine.raiseF();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJc();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseJc();
+		statemachine.raiseJd();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C1));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+		statemachine.raiseE();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_B_r1_C2));
+		assertTrue(statemachine.isStateActive(State.main_region_B_r2_D2));
+	}
+}

+ 46 - 46
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/sct/generator/java/test/ValuedEventTest.java

@@ -1,46 +1,46 @@
-/**
- * Copyright (c) 2012 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.valuedevents.ValuedEventsStatemachine;
-import org.yakindu.scr.valuedevents.ValuedEventsStatemachine.State;
-/**
- *  Unit TestCase for ValuedEvents
- */
-@SuppressWarnings("all")
-public class ValuedEventTest {
-
-	private ValuedEventsStatemachine statemachine;
-
-	@Before
-	public void setUp() {
-		statemachine = new ValuedEventsStatemachine();
-		statemachine.init();
-	}
-
-	@After
-	public void tearDown() {
-		statemachine = null;
-	}
-
-	@Test
-	public void testvaluedEventTest() {
-		statemachine.enter();
-		statemachine.runCycle();
-		assertTrue(statemachine.isStateActive(State.main_region_A));
-		assertTrue(statemachine.isStateActive(State._region1_C));
-		assertTrue(statemachine.getMyVar() == 42);
-	}
-}
+/**
+ * Copyright (c) 2012 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.valuedevents.ValuedEventsStatemachine;
+import org.yakindu.scr.valuedevents.ValuedEventsStatemachine.State;
+/**
+ *  Unit TestCase for ValuedEvents
+ */
+@SuppressWarnings("all")
+public class ValuedEventTest {
+
+	private ValuedEventsStatemachine statemachine;
+
+	@Before
+	public void setUp() {
+		statemachine = new ValuedEventsStatemachine();
+		statemachine.init();
+	}
+
+	@After
+	public void tearDown() {
+		statemachine = null;
+	}
+
+	@Test
+	public void testvaluedEventTest() {
+		statemachine.enter();
+		statemachine.runCycle();
+		assertTrue(statemachine.isStateActive(State.main_region_A));
+		assertTrue(statemachine.isStateActive(State._region1_C));
+		assertTrue(statemachine.getMyVar() == 42);
+	}
+}

+ 1 - 0
test-plugins/org.yakindu.sct.test.models/.settings/org.eclipse.core.resources.prefs

@@ -1,6 +1,7 @@
 eclipse.preferences.version=1
 eclipse.preferences.version=1
 encoding//testmodels/AlwaysOncycle.sct=UTF-8
 encoding//testmodels/AlwaysOncycle.sct=UTF-8
 encoding//testmodels/AssignmentAsExpression.sct=UTF-8
 encoding//testmodels/AssignmentAsExpression.sct=UTF-8
+encoding//testmodels/Declarations.sct=UTF-8
 encoding//testmodels/ExitOnSelfTransition.sct=UTF-8
 encoding//testmodels/ExitOnSelfTransition.sct=UTF-8
 encoding//testmodels/GuardedEntry.sct=UTF-8
 encoding//testmodels/GuardedEntry.sct=UTF-8
 encoding//testmodels/GuardedExit.sct=UTF-8
 encoding//testmodels/GuardedExit.sct=UTF-8

BIN
test-plugins/org.yakindu.sct.test.models/images/Declarations.png


+ 11 - 0
test-plugins/org.yakindu.sct.test.models/src/util/TestModels.java

@@ -37,6 +37,7 @@ public class TestModels {
 	public static final String BIT_EXPRESSIONS = "BitExpressions.sct";
 	public static final String BIT_EXPRESSIONS = "BitExpressions.sct";
 	public static final String BOOLEAN_EXPRESSIONS = "BooleanExpressions.sct";
 	public static final String BOOLEAN_EXPRESSIONS = "BooleanExpressions.sct";
 	public static final String C_KEYWORDS_M = "CKeywords.sct";
 	public static final String C_KEYWORDS_M = "CKeywords.sct";
+	public static final String DECLARATIONS = "Declarations.sct";
 	public static final String CHOICE = "Choice.sct";
 	public static final String CHOICE = "Choice.sct";
 	public static final String DEEP_HISTORY = "DeepHistory.sct";
 	public static final String DEEP_HISTORY = "DeepHistory.sct";
 	public static final String FEATURE_CALLS = "FeatureCalls.sct";
 	public static final String FEATURE_CALLS = "FeatureCalls.sct";
@@ -113,6 +114,16 @@ public class TestModels {
 	public ExecutionFlow createCKeywordModel() throws IOException {
 	public ExecutionFlow createCKeywordModel() throws IOException {
 		return loadExecutionFlowFromResource(C_KEYWORDS_M);
 		return loadExecutionFlowFromResource(C_KEYWORDS_M);
 	}
 	}
+	
+	/**
+	 * <img src="../../images/Declarations.png" /> <br />
+	 * 
+	 * @return the {@link ExecutionFlow}
+	 * @throws IOException
+	 */
+	public ExecutionFlow createDeclarationsModel() throws IOException {
+		return loadExecutionFlowFromResource(DECLARATIONS);
+	}
 
 
 	/**
 	/**
 	 * <img src="../../images/DeepHistory.png" /> <br />
 	 * <img src="../../images/DeepHistory.png" /> <br />

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 72 - 0
test-plugins/org.yakindu.sct.test.models/testmodels/Declarations.sct


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

@@ -1,6 +1,6 @@
 testsuite AllTests { 
 testsuite AllTests { 
 	AlwaysOncycle , AssignmentAsExpression, BitExpressions , BooleanExpressions , CKeywords,
 	AlwaysOncycle , AssignmentAsExpression, BitExpressions , BooleanExpressions , CKeywords,
-	Choice , DeepHistory,
+	Declarations, Choice , DeepHistory,
 	ExitOnSelfTransition,
 	ExitOnSelfTransition,
 	//FeatureCalls,
 	//FeatureCalls,
 	Guard, 
 	Guard, 

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

@@ -0,0 +1,7 @@
+testgroup Declarations for statechart Declarations {
+	
+	test declarationsTest {
+		
+		enter
+	}
+}