Skip to content

Commit

Permalink
Don’t modify the helper, just include in the parent module
Browse files Browse the repository at this point in the history
  • Loading branch information
joeldrapper committed Sep 7, 2024
1 parent 425e555 commit 7267eed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/phlex/testing/capybara.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ module Phlex::Testing::Capybara
def self.included(mod)
if defined?(Minitest::Test) && Minitest::Test > mod
require "capybara/minitest"
include Capybara::Minitest::Assertions
mod.include Capybara::Minitest::Assertions
end

if defined?(RSpec::Core::ExampleGroup) && RSpec::Core::ExampleGroup > mod
require "capybara/rspec"
include Capybara::RSpecMatchers
mod.include Capybara::RSpecMatchers
end
end

Expand Down

0 comments on commit 7267eed

Please sign in to comment.