Specifications:
Validate that a signal group can be ordered to green using the M0010 command.
-
Verify connection
-
Send control command to start signalgrup, set_signal_start= true, include security_code
-
Wait for status = true
11 12 13 14
# File 'spec/site/tlc/signal_groups_spec.rb', line 11 Validator::Site.connected do |task,supervisor,site| prepare task, site set_signal_start end
-
-
Verify connection
-
Send control command to stop signalgrup, set_signal_start= false, include security_code
-
Wait for status = true
21 22 23 24
# File 'spec/site/tlc/signal_groups_spec.rb', line 21 Validator::Site.connected do |task,supervisor,site| prepare task, site set_signal_stop end
-
Verify that signal group status can be read with S0001.
-
Given the site is connected
-
Request status
-
Expect status response before timeout
33 34 35 36
# File 'spec/site/tlc/signal_groups_spec.rb', line 33 Validator::Site.connected do |task,supervisor,site| request_status_and_confirm site, "signal group status", { S0001: [:signalgroupstatus, :cyclecounter, :basecyclecounter, :stage] } end
-
Verify that time-of-green/time-of-red can be read with S0025.
-
Given the site is connected
-
Request status
-
Expect status response before timeout
45 46 47 48 49 50 51 52 53 54 55 56 57
# File 'spec/site/tlc/signal_groups_spec.rb', line 45 Validator::Site.connected do |task,supervisor,site| request_status_and_confirm site, "time-of-green/time-of-red", { S0025: [ :minToGEstimate, :maxToGEstimate, :likelyToGEstimate, :ToGConfidence, :minToREstimate, :maxToREstimate, :likelyToREstimate ] }, Validator.get_config('components','signal_group').keys.first end
-
Verify status S0017 number of signal groups
-
Given the site is connected
-
Request status
-
Expect status response before timeout
66 67 68 69
# File 'spec/site/tlc/signal_groups_spec.rb', line 66 Validator::Site.connected do |task,supervisor,site| request_status_and_confirm site, "number of signal groups", { S0017: [:number] } end
-
Verify that we can activate normal control after yellow flash mode is turned off
-
Given the site is connected and in yellow flash mode
-
When we activate normal control
-
All signal groups should go through e, f and g
78 79 80 81 82 83 84 85
# File 'spec/site/tlc/signal_groups_spec.rb', line 78 Validator::Site.connected do |task,supervisor,site| prepare task, site verify_startup_sequence do switch_yellow_flash set_functional_position 'NormalControl' end set_functional_position 'NormalControl' end
-