Loading ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_001.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -28,7 +28,7 @@ module NegSem_200502_the_activate_operation_001 { } testcase TC_NegSem_200502_the_activate_operation_001() runs on GeneralComp { a(); activate(a()); setverdict(pass); } Loading ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_006.ttcn 0 → 100644 +47 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, local timer as a parameter of activated altstep in module control ** @verdict pass reject ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module NegSem_200502_the_activate_operation_006 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_NegSem_200502_the_activate_operation_006() runs on GeneralComp { setverdict(pass); } function f_test() { timer t_tmr := 1.0, t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } } control{ f_test(); execute(TC_NegSem_200502_the_activate_operation_006()); } } ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_007.ttcn 0 → 100644 +52 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, local timer (referenced through timer parameter) as a parameter of activated altstep in module control ** @verdict pass reject ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module NegSem_200502_the_activate_operation_007 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_NegSem_200502_the_activate_operation_007() runs on GeneralComp { setverdict(pass); } function f_activate(timer t_tmr) { activate(a(t_tmr)); } function f_test() { timer t_tmr := 1.0; t_tmr.start; f_activate(t_tmr); // t_tmr is a local timer, this should lead to an activation error in f_activate } control{ timer t_tmr2; f_test(); alt { [] t_tmr2.timeout { } } execute(TC_NegSem_200502_the_activate_operation_007()); } } ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/Sem_200502_the_activate_operation_005.ttcn 0 → 100644 +43 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, control block timer as a parameter of activated altstep ** @verdict pass accept, ttcn3verdict:pass ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module Sem_200502_the_activate_operation_005 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_Sem_200502_the_activate_operation_005() runs on GeneralComp { setverdict(pass); } control{ timer t_tmr := 1.0, t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } execute(TC_Sem_200502_the_activate_operation_005()); } } ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/Sem_200502_the_activate_operation_006.ttcn 0 → 100644 +48 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, control block timer (referenced through timer parameter) as a parameter of activated altstep ** @verdict pass accept, ttcn3verdict:pass ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module Sem_200502_the_activate_operation_006 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_Sem_200502_the_activate_operation_006() runs on GeneralComp { setverdict(pass); } function f_test(timer t_tmr) { timer t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } } control{ timer t_tmr := 1.0; f_test(t_tmr); execute(TC_Sem_200502_the_activate_operation_006()); } } Loading
ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_001.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -28,7 +28,7 @@ module NegSem_200502_the_activate_operation_001 { } testcase TC_NegSem_200502_the_activate_operation_001() runs on GeneralComp { a(); activate(a()); setverdict(pass); } Loading
ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_006.ttcn 0 → 100644 +47 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, local timer as a parameter of activated altstep in module control ** @verdict pass reject ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module NegSem_200502_the_activate_operation_006 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_NegSem_200502_the_activate_operation_006() runs on GeneralComp { setverdict(pass); } function f_test() { timer t_tmr := 1.0, t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } } control{ f_test(); execute(TC_NegSem_200502_the_activate_operation_006()); } }
ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/NegSem_200502_the_activate_operation_007.ttcn 0 → 100644 +52 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, local timer (referenced through timer parameter) as a parameter of activated altstep in module control ** @verdict pass reject ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module NegSem_200502_the_activate_operation_007 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_NegSem_200502_the_activate_operation_007() runs on GeneralComp { setverdict(pass); } function f_activate(timer t_tmr) { activate(a(t_tmr)); } function f_test() { timer t_tmr := 1.0; t_tmr.start; f_activate(t_tmr); // t_tmr is a local timer, this should lead to an activation error in f_activate } control{ timer t_tmr2; f_test(); alt { [] t_tmr2.timeout { } } execute(TC_NegSem_200502_the_activate_operation_007()); } }
ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/Sem_200502_the_activate_operation_005.ttcn 0 → 100644 +43 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, control block timer as a parameter of activated altstep ** @verdict pass accept, ttcn3verdict:pass ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module Sem_200502_the_activate_operation_005 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_Sem_200502_the_activate_operation_005() runs on GeneralComp { setverdict(pass); } control{ timer t_tmr := 1.0, t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } execute(TC_Sem_200502_the_activate_operation_005()); } }
ATS/20_statement_and_operations_for_alt/2005_default_handling/200502_the_activate_operation/Sem_200502_the_activate_operation_006.ttcn 0 → 100644 +48 −0 Original line number Diff line number Diff line /*************************************************** ** @author STF 487 ** @version 0.0.1 ** @purpose 1:20.5.2, control block timer (referenced through timer parameter) as a parameter of activated altstep ** @verdict pass accept, ttcn3verdict:pass ***************************************************/ // The following requirement is tested: // For altsteps activated in module control or in functions or altsteps invoked // directly or indirectly from module control, all timer instances in the actual // parameter list shall be declared in the highest scope of the module control // part (see clause 26.2). Timers from lower scopes of the module control part // (i.e. from the nested statement blocks) are not allowed to occur in the actual // parameter list. module Sem_200502_the_activate_operation_006 { type port P message { inout integer; } type component GeneralComp { port P p; } altstep a(timer t_tmr) { [] t_tmr.timeout { log ("Timeout in default"); } } testcase TC_Sem_200502_the_activate_operation_006() runs on GeneralComp { setverdict(pass); } function f_test(timer t_tmr) { timer t_tmr2; t_tmr.start; activate(a(t_tmr)); alt { [] t_tmr2.timeout { } } } control{ timer t_tmr := 1.0; f_test(t_tmr); execute(TC_Sem_200502_the_activate_operation_006()); } }