diff options
Diffstat (limited to 'spec/support/helpers/live_debugger.rb')
-rw-r--r-- | spec/support/helpers/live_debugger.rb | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/spec/support/helpers/live_debugger.rb b/spec/support/helpers/live_debugger.rb index d6091035b59..cdb068760f4 100644 --- a/spec/support/helpers/live_debugger.rb +++ b/spec/support/helpers/live_debugger.rb @@ -6,11 +6,17 @@ module LiveDebugger def live_debug puts puts "Current example is paused for live debugging." - puts "Opening #{current_url} in your default browser..." + + if ENV['CHROME_HEADLESS'] =~ /^(false|no|0)$/i + puts "Switch to the Chrome window that was automatically opened to run the test in order to view current page" + else + puts "Opening #{current_url} in your default browser..." + end + puts "The current user credentials are: #{@current_user.username} / #{@current_user.password}" if @current_user puts "Press any key to resume the execution of the example!!" - `open #{current_url}` + `open #{current_url}` if ENV['CHROME_HEADLESS'] !~ /^(false|no|0)$/i loop until $stdin.getch |