Class: Capybara::Session
- Inherits:
-
Object
- Object
- Capybara::Session
- Defined in:
- lib/capybara/screenshot_config.rb
Overview
monkey patching Capybara::Session#save_screenshot
Instance Method Summary collapse
Instance Method Details
#old_save_screenshot ⇒ Object
20 |
# File 'lib/capybara/screenshot_config.rb', line 20 alias_method :old_save_screenshot, :save_screenshot |
#save_screenshot(path, options = {}) ⇒ Object
22 23 24 25 26 |
# File 'lib/capybara/screenshot_config.rb', line 22 def save_screenshot(path, ={}) = ScreenshotConfig.configuration..merge() old_save_screenshot("#{ScreenshotConfig.configuration.save_dir}/#{path}", ) end |