Sha256: d5f2b17802fb66a6d5256ecb68f19a4ea1158db1e51189c9e1479638b41417b7
Contents?: true
Size: 382 Bytes
Versions: 3
Compression:
Stored size: 382 Bytes
Contents
driver = Selenium::WebDriver.for :chrome Before do @driver = driver @driver.manage.delete_all_cookies end After do |scenario| if scenario.failed? begin encoded_img = driver.screenshot_as(:base64) embed("#{encoded_img}", "image/png;base64") rescue p "*** Could not take failed scenario screenshot ***" end end end at_exit do driver.quit end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
web-object-0.5 | features/support/hooks.rb |
web-object-0.4 | features/support/hooks.rb |
web-object-0.3 | features/support/hooks.rb |