Class: Capybara::Rails::TestCase
- Inherits:
-
ActiveSupport::TestCase
- Object
- ActiveSupport::TestCase
- Capybara::Rails::TestCase
- Includes:
- Assertions, DSL, Minitest::Metadata
- Defined in:
- lib/minitest/rails/capybara.rb
Instance Method Summary collapse
-
#__rails_helpers__ ⇒ Object
Defer rails helpers methods to a different object.
-
#method_missing(sym, *args, &block) ⇒ Object
:nodoc:.
-
#respond_to?(method, include_private = false) ⇒ Boolean
:nodoc:.
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(sym, *args, &block) ⇒ Object
:nodoc:
54 55 56 57 58 59 60 |
# File 'lib/minitest/rails/capybara.rb', line 54 def method_missing(sym, *args, &block) # :nodoc: if __rails_helpers__.respond_to?(sym, true) __rails_helpers__.__send__(sym, *args, &block) else super end end |
Instance Method Details
#__rails_helpers__ ⇒ Object
Defer rails helpers methods to a different object
48 49 50 |
# File 'lib/minitest/rails/capybara.rb', line 48 def __rails_helpers__ # :nodoc: @__rails_helpers__ ||= ::Capybara::Rails::Helpers.new end |
#respond_to?(method, include_private = false) ⇒ Boolean
:nodoc:
51 52 53 |
# File 'lib/minitest/rails/capybara.rb', line 51 def respond_to?(method, include_private = false) # :nodoc: __rails_helpers__.respond_to?(method, include_private) || super end |