Rev | Line | |
---|
[4] | 1 | module checkInconcOrFailSetverdictPrecededByLog { |
---|
| 2 | |
---|
| 3 | testcase t_sendMsg() runs on myComponent { |
---|
| 4 | p1.send(msg_a); |
---|
| 5 | |
---|
| 6 | // this is as expected |
---|
| 7 | alt { |
---|
| 8 | [] p2.receive(msg_b) { |
---|
| 9 | someOtherfunction(); |
---|
| 10 | log("*** t_sendMsg: INFO: Wrong message has been received ***") |
---|
| 11 | setverdict(fail); |
---|
| 12 | someOtherfunction(); |
---|
| 13 | } |
---|
| 14 | [] p2.receive(msg_c) { |
---|
| 15 | setverdict(pass); |
---|
| 16 | } |
---|
| 17 | [] p2.receive { |
---|
| 18 | log("*** t_sendMsg: INFO: Unexpected message, possibly malicious ***"); |
---|
| 19 | setverdict(inconc); |
---|
| 20 | } |
---|
| 21 | } |
---|
| 22 | // here, the log statements are missing |
---|
| 23 | alt { |
---|
| 24 | [] p2.receive(msg_b) { |
---|
| 25 | setverdict(fail); |
---|
| 26 | } |
---|
| 27 | [] p2.receive(msg_c) { |
---|
| 28 | setverdict(pass); |
---|
| 29 | } |
---|
| 30 | [] p2.receive { |
---|
| 31 | setverdict(inconc); |
---|
| 32 | } |
---|
| 33 | } |
---|
| 34 | |
---|
| 35 | } |
---|
| 36 | |
---|
| 37 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.