aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/testing
diff options
context:
space:
mode:
authorRyuta Kamizono <kamipo@gmail.com>2017-04-22 18:29:05 +0900
committerRyuta Kamizono <kamipo@gmail.com>2017-04-22 23:11:15 +0900
commitca9ac310028d0009edf1fbf657541d2dea327535 (patch)
tree83fd7c9fcbe6410ca670ae15439e85fe8c95188e /actionpack/lib/action_dispatch/testing
parent0541a0d5481043a9c78371446389794944daf3f0 (diff)
downloadrails-ca9ac310028d0009edf1fbf657541d2dea327535.tar.gz
rails-ca9ac310028d0009edf1fbf657541d2dea327535.tar.bz2
rails-ca9ac310028d0009edf1fbf657541d2dea327535.zip
`respond_to_missing?` should be private
Follow up of 03d3f036. Some of `respond_to?` were replaced to `respond_to_missing?` in 03d3f036. But the visibility is still public. It should be private.
Diffstat (limited to 'actionpack/lib/action_dispatch/testing')
-rw-r--r--actionpack/lib/action_dispatch/testing/integration.rb11
1 files changed, 6 insertions, 5 deletions
diff --git a/actionpack/lib/action_dispatch/testing/integration.rb b/actionpack/lib/action_dispatch/testing/integration.rb
index 2e2db98ad6..2416c58817 100644
--- a/actionpack/lib/action_dispatch/testing/integration.rb
+++ b/actionpack/lib/action_dispatch/testing/integration.rb
@@ -385,14 +385,15 @@ module ActionDispatch
integration_session.default_url_options = options
end
- def respond_to_missing?(method, include_private = false)
- integration_session.respond_to?(method, include_private) || super
+ private
+ def respond_to_missing?(method, _)
+ integration_session.respond_to?(method) || super
end
# Delegate unhandled messages to the current session instance.
- def method_missing(sym, *args, &block)
- if integration_session.respond_to?(sym)
- integration_session.__send__(sym, *args, &block).tap do
+ def method_missing(method, *args, &block)
+ if integration_session.respond_to?(method)
+ integration_session.public_send(method, *args, &block).tap do
copy_session_variables!
end
else