Class: RkCucumber::Messages
- Inherits:
-
Object
- Object
- RkCucumber::Messages
- Defined in:
- lib/results_keeper/messages.rb
Class Method Summary collapse
- .console_message(text) ⇒ Object
- .console_warning_message(text) ⇒ Object
- .error_not_sent_scenario(amount) ⇒ Object
- .error_send_screenshot ⇒ Object
- .info_message_to_client(response, message_to_client = nil) ⇒ Object
-
.info_trying_resend(scenario_name) ⇒ Object
INFO.
- .no_secret_key ⇒ Object
-
.take_screenshot_error ⇒ Object
ERROR.
-
.warn_problem_with_rk ⇒ Object
WARN.
Class Method Details
.console_message(text) ⇒ Object
39 40 41 42 |
# File 'lib/results_keeper/messages.rb', line 39 def (text) private puts " Results Keeper: #{text}".blue unless ENV['HIDE_RK_MESSAGES'] == 'true' end |
.console_warning_message(text) ⇒ Object
44 45 46 47 |
# File 'lib/results_keeper/messages.rb', line 44 def (text) private puts " Results Keeper: #{text}".yellow unless ENV['HIDE_RK_MESSAGES'] == 'true' end |
.error_not_sent_scenario(amount) ⇒ Object
17 18 19 |
# File 'lib/results_keeper/messages.rb', line 17 def error_not_sent_scenario(amount) ("Not sent scenarios amount: #{amount}") end |
.error_send_screenshot ⇒ Object
13 14 15 |
# File 'lib/results_keeper/messages.rb', line 13 def error_send_screenshot ("Could not send screenshot, there seems to be a problem with #{RkCucumber::Config.config[:report_server_host]}:#{RkCucumber::Config.config[:report_server_port]}") end |
.info_message_to_client(response, message_to_client = nil) ⇒ Object
30 31 32 |
# File 'lib/results_keeper/messages.rb', line 30 def (response, =nil) ? ("#{} - #{response.code} - #{response.}") : ("#{response.code} - #{response.}") end |
.info_trying_resend(scenario_name) ⇒ Object
INFO
26 27 28 |
# File 'lib/results_keeper/messages.rb', line 26 def (scenario_name) ("Trying to re-send '#{scenario_name}' once more") end |
.no_secret_key ⇒ Object
21 22 23 |
# File 'lib/results_keeper/messages.rb', line 21 def no_secret_key 'RK_SECRET_KEY env var not found. Please use export RK_SECRET_KEY=<your secret key> to set it.' end |
.take_screenshot_error ⇒ Object
ERROR
9 10 11 |
# File 'lib/results_keeper/messages.rb', line 9 def take_screenshot_error ('Could not take a screenshot :(') end |
.warn_problem_with_rk ⇒ Object
WARN
35 36 37 |
# File 'lib/results_keeper/messages.rb', line 35 def warn_problem_with_rk ("There seems to be a problem with #{RkCucumber::Config.config[:report_server_host]}:#{RkCucumber::Config.config[:report_server_port]}, make sure your RK_SECRET_KEY is correct and server is up.") end |