summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-12-07 14:01:30 +0100
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-12-07 14:01:46 +0100
commit043810f7f4cdf050ff6a32a743a352fa68754274 (patch)
tree73cf2a4ec1c143390af12e2b6ff1239c21876c5b
parentfc00d739fcf86b5dbd22cf0eb3c57072ea5b439f (diff)
downloadgitlab-ce-043810f7f4cdf050ff6a32a743a352fa68754274.tar.gz
Fix runtime QA browser and capturing screenshots
[ci skip]
-rw-r--r--qa/qa/runtime/browser.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/qa/qa/runtime/browser.rb b/qa/qa/runtime/browser.rb
index 2226c56c012..16fa3a1bd23 100644
--- a/qa/qa/runtime/browser.rb
+++ b/qa/qa/runtime/browser.rb
@@ -6,7 +6,7 @@ require 'selenium-webdriver'
module QA
module Runtime
class Browser
- include Scenario::Actable
+ include QA::Scenario::Actable
def initialize
self.class.configure!
@@ -63,9 +63,11 @@ module QA
block.call if block_given?
rescue
+ raise if block.nil?
+
# RSpec examples will take care of screenshots on their own
#
- unless block.binding.receiver.class < RSpec::Core::ExampleGroup
+ unless block.binding.receiver.is_a?(RSpec::Core::ExampleGroup)
Capybara::Screenshot.screenshot_and_save_page
end