use of org.yakindu.sct.model.sexec.transformation.test.SCTTestUtil.InitializingTSC in project statecharts by Yakindu.
the class ModelSequencerSCTest method testSCInitSequence_Variables.
/**
* The init sequence must contain variable initialization.
*/
@Test
public void testSCInitSequence_Variables() {
InitializingTSC tsc = new InitializingTSC();
ExecutionFlow flow = sequencer.transform(tsc.sc);
assertNotNull(flow.getInitSequence());
assertEquals(1, flow.getInitSequence().getSteps().size());
assertAssignment(flow.getInitSequence(), 0, "e1", AssignmentOperator.ASSIGN, "true");
}
use of org.yakindu.sct.model.sexec.transformation.test.SCTTestUtil.InitializingTSC in project statecharts by Yakindu.
the class ModelSequencerSCTest method testSCEnterSequence_Variables.
/**
* The enter step must not contain variable initialization.
*/
@Test
public void testSCEnterSequence_Variables() {
InitializingTSC tsc = new InitializingTSC();
ExecutionFlow flow = sequencer.transform(tsc.sc);
assertNotNull(flow.getEnterSequences().get(0));
assertEquals(1, flow.getEnterSequences().get(0).getSteps().size());
assertCall(flow.getEnterSequences().get(0), 0, flow.getEntryAction());
}
Aggregations