/** * @author axel terfloth */ testclass OutEventLifeCycle for statechart OutEventLifeCycle { /* an outgoing event must be accessible after the cycle that raised the event. */ @Test operation availableAfterCycle(){ enter raise e proceed 1 cycle assert f } /* an outgoing event must be accessible within the cycle that raised the event. */ @Test operation availableWithinCycle(){ init(false) assert f_available_in_cycle } /* an outgoing event that was raised in one cycle is not available within the next cycle */ @Test operation unvailableWithin2ndCycle(){ init(true) assert ! f_available_in_next_cycle } /* an outgoing event that was raised in one cycle is not available after the following cycle */ @Test operation unvailableAfter2ndCycle(){ init(true) assert !f } operation init(sndCycle : boolean){ enter raise e proceed 1 cycle if(sndCycle){ proceed 1 cycle } } }