mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-19 11:06:03 +01:00
feat(simulation): test.no_movement_before_pass, a pass that doesn't wait for a stop
The config key from eu07/maszyna#541. By default (yes) a pass reported to __test.result waits until every vehicle has stood still for 1 s; with no it ends the test at once. The key is listed with the other test.* settings in the log and in the test start line. Scenario tests: new case test_mode_pass_while_moving reports the pass from event2 of tor1k as the train runs onto it and checks the run ended with the train still moving (new check ends_moving). The README lists the test.* keys with their defaults and the input the test mode ignores.
This commit is contained in:
28
tests/scenarios/cases/test_mode_pass_while_moving.json
Normal file
28
tests/scenarios/cases/test_mode_pass_while_moving.json
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"description": "Test mode, pass without waiting for a stop: like test_mode_pass, but event2 of the track in front of the exit signal reports the pass as the train runs onto it, and with test.no_movement_before_pass no the test ends at once, the train still moving.",
|
||||
"base_scenery": "td.scn",
|
||||
"time": "10:34",
|
||||
"fragment": "td_red_signal_pass.scn",
|
||||
"track_events": {
|
||||
"tor1k": "event2 test_pass"
|
||||
},
|
||||
"test_config": [
|
||||
"test.no_movement_before_pass no"
|
||||
],
|
||||
"vars": {
|
||||
"consist": "node -1 0 {{vehicle}} dynamic pkp\\4e_v1 4e-004 4e 0 headdriver 0 0 enddynamic"
|
||||
},
|
||||
"expect": "pass",
|
||||
"timeout": 600,
|
||||
"checks": [
|
||||
{
|
||||
"type": "starts",
|
||||
"min_speed": 5,
|
||||
"within": 150
|
||||
},
|
||||
{
|
||||
"type": "ends_moving",
|
||||
"min_speed": 3
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user