module CapybaraScreenshotDiff::Minitest::Assertions
Public Instance Methods
Source
# File lib/capybara_screenshot_diff/minitest.rb, line 37 def before_teardown super CapybaraScreenshotDiff.verify rescue CapybaraScreenshotDiff::ExpectationNotMet => e assertion = ::Minitest::Assertion.new(e) assertion.set_backtrace [] failures << assertion ensure CapybaraScreenshotDiff.reset end
Calls superclass method
Source
# File lib/capybara_screenshot_diff/minitest.rb, line 22 def screenshot(*args, skip_stack_frames: 0, **opts) self.assertions += 1 super(*args, skip_stack_frames: skip_stack_frames + 3, **opts) rescue ::CapybaraScreenshotDiff::ExpectationNotMet => e raise ::Minitest::Assertion, e.message end
Calls superclass method
CapybaraScreenshotDiff::DSL#screenshot
Also aliased as: assert_matches_screenshot
Source
# File lib/capybara_screenshot_diff/minitest.rb, line 32 def setup super ::Capybara::Screenshot::BrowserHelpers.resize_window_if_needed end
Calls superclass method