Specifications:

  • Traffic Light Controller System operator logged in/out of OP-panel is read with S0091

    Verify status S0091 operator logged in/out OP-panel

    1. Given the site is connected

    2. Request status

    3. Expect status response before timeout

    
    
    11
    12
    13
    14
    15
    16
    17
    18
    # File 'spec/site/tlc/system_spec.rb', line 11
    
    Validator::Site.connected do |task,supervisor,site|
            if RSMP::Proxy.version_meets_requirement?( site.sxl_version, '>=1.1' )
              status_list = { S0091: [:user] }
            else
              status_list = { S0091: [:user, :status] }
            end
            request_status_and_confirm site, "operator logged in/out OP-panel", status_list
          end
  • Traffic Light Controller System operator logged in/out of web-interface is read with S0092

    Verify status S0092 operator logged in/out web-interface

    1. Given the site is connected

    2. Request status

    3. Expect status response before timeout

    
    
    27
    28
    29
    30
    31
    32
    33
    34
    # File 'spec/site/tlc/system_spec.rb', line 27
    
    Validator::Site.connected do |task,supervisor,site|
            if RSMP::Proxy.version_meets_requirement?( site.sxl_version, '>=1.1' )
              status_list = { S0092: [:user] }
            else
              status_list = { S0092: [:user, :status] }
            end
            request_status_and_confirm site, "operator logged in/out web-interface", status_list
          end
  • Traffic Light Controller System version is read with S0095

    Verify status S0095 version of traffic controller

    1. Given the site is connected

    2. Request status

    3. Expect status response before timeout

    
    
    43
    44
    45
    46
    # File 'spec/site/tlc/system_spec.rb', line 43
    
    Validator::Site.connected do |task,supervisor,site|
            request_status_and_confirm site, "version of traffic controller",
            { S0095: [:status] }
          end
  • Traffic Light Controller System security code is set with M0103
    1. Verify connection

    2. Send control command to set securitycode_level

    3. Wait for status = true

    4. Send control command to setsecuritycode_level

    5. Wait for status = true

    
    
    55
    56
    57
    58
    59
    # File 'spec/site/tlc/system_spec.rb', line 55
    
    Validator::Site.connected do |task,supervisor,site|
            prepare task, site
            set_security_code 1
            set_security_code 2
          end
  • Traffic Light Controller System security code is rejected when incorrect

    Verify that the site responds with NotAck if we send incorrect security cdoes. RThis hehaviour is defined in SXL >= 1.1. For earlier versions, The behaviour is undefined.

    1. Given the site is connected

    2. When we send a M0008 command with incorrect security codes

    3. Then we should received a NotAck

    
    
    69
    70
    71
    72
    # File 'spec/site/tlc/system_spec.rb', line 69
    
    Validator::Site.connected do |task,supervisor,site|
            prepare task, site
            expect { wrong_security_code }.to raise_error(RSMP::MessageRejected)
          end