Improve expectation in rc key test scenario (UAT)

This commit is contained in:
Thibault Jouan
2015-04-28 09:42:39 +00:00
parent a6b2e98146
commit 27448abfc6

View File

@@ -3,31 +3,31 @@ Feature: `key' run control keyword
Scenario: defines code to run when given key is pressed Scenario: defines code to run when given key is pressed
Given uhwm is running with this run control file: Given uhwm is running with this run control file:
""" """
key(:f) { puts 'trigger f key code' } key(:f) { puts 'testing_rc_key' }
""" """
When I press the alt+f keys When I press the alt+f keys
Then the output must contain "trigger f key code" Then the output must contain "testing_rc_key"
Scenario: defines code to run when given keys are pressed Scenario: defines code to run when given keys are pressed
Given uhwm is running with this run control file: Given uhwm is running with this run control file:
""" """
key(:f, :shift) { puts 'trigger f key code' } key(:f, :shift) { puts 'testing_rc_key' }
""" """
When I press the alt+shift+f keys When I press the alt+shift+f keys
Then the output must contain "trigger f key code" Then the output must contain "testing_rc_key"
Scenario: translates common key names to their X equivalent Scenario: translates common key names to their X equivalent
Given uhwm is running with this run control file: Given uhwm is running with this run control file:
""" """
key(:enter) { puts 'trigger return key code' } key(:enter) { puts 'testing_rc_key' }
""" """
When I press the alt+Return keys When I press the alt+Return keys
Then the output must contain "trigger return key code" Then the output must contain "testing_rc_key"
Scenario: translates upcased key names to combination with shift key Scenario: translates upcased key names to combination with shift key
Given uhwm is running with this run control file: Given uhwm is running with this run control file:
""" """
key(:F) { puts 'trigger shift+f key code' } key(:F) { puts 'testing_rc_key' }
""" """
When I press the alt+shift+f keys When I press the alt+shift+f keys
Then the output must contain "trigger shift+f key code" Then the output must contain "testing_rc_key"