Module: ActionController::Rescue
- Defined in:
- lib/vendor/plugins/rspec-rails/lib/spec/rails/extensions/action_controller/rescue.rb
Instance Method Summary collapse
Instance Method Details
#use_rails_error_handling! ⇒ Object
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/vendor/plugins/rspec-rails/lib/spec/rails/extensions/action_controller/rescue.rb', line 3 def use_rails_error_handling! Kernel.warn "DEPRECATION NOTICE: controller.use_rails_error_handling! is\ndeprecated and will be removed from a future version of\nrspec-rails.\n\nUse rescue_action_in_public!, which is defined directly in\nrails' testing framework, instead.\n" if ::Rails::VERSION::STRING =~ /^2\.0/ @use_rails_error_handling = true else # anything but 0.0.0.0 - borrowed from rails own rescue_action_in_public! request.remote_addr = '208.77.188.166' end end |
#use_rails_error_handling? ⇒ Boolean
20 21 22 |
# File 'lib/vendor/plugins/rspec-rails/lib/spec/rails/extensions/action_controller/rescue.rb', line 20 def use_rails_error_handling? @use_rails_error_handling ||= false end |