Class: Shoulda::Matchers::Integrations::Libraries::ActionController
- Inherits:
-
Object
- Object
- Shoulda::Matchers::Integrations::Libraries::ActionController
- Defined in:
- lib/shoulda/matchers/integrations/libraries/action_controller.rb
Instance Method Summary collapse
Methods included from Rails
Methods included from Inclusion
Instance Method Details
#integrate_with(test_framework) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/shoulda/matchers/integrations/libraries/action_controller.rb', line 12 def integrate_with(test_framework) test_framework.include(matchers_module, type: :controller) tap do |instance| ActiveSupport.on_load(:action_controller_test_case, run_once: true) do instance.include_into(::ActionController::TestCase, instance.matchers_module) do def subject # rubocop:disable Lint/NestedMethodDefinition @controller end end end end end |
#matchers_module ⇒ Object
26 27 28 |
# File 'lib/shoulda/matchers/integrations/libraries/action_controller.rb', line 26 def matchers_module Shoulda::Matchers::ActionController end |