aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2011-12-29 17:27:10 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2011-12-30 10:02:49 -0800
commit5681f79f642c57397bf18d239a9aa1dbf71b0f24 (patch)
treedf639b5988721ab0faf8d73a57b9f4de632b3bf5 /actionpack
parent116b9edf95ccaa59feb6afe67b126ad3da526b92 (diff)
downloadrails-5681f79f642c57397bf18d239a9aa1dbf71b0f24.tar.gz
rails-5681f79f642c57397bf18d239a9aa1dbf71b0f24.tar.bz2
rails-5681f79f642c57397bf18d239a9aa1dbf71b0f24.zip
be explicit about where helpers are installed
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_dispatch/routing/route_set.rb2
-rw-r--r--actionpack/test/controller/action_pack_assertions_test.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb
index c60e26983d..10b3e212e6 100644
--- a/actionpack/lib/action_dispatch/routing/route_set.rb
+++ b/actionpack/lib/action_dispatch/routing/route_set.rb
@@ -276,7 +276,7 @@ module ActionDispatch
@prepend.each { |blk| eval_block(blk) }
end
- def install_helpers(destinations = [ActionController::Base, ActionView::Base])
+ def install_helpers(destinations)
destinations.each { |d| d.module_eval { include Helpers } }
named_routes.install(destinations)
end
diff --git a/actionpack/test/controller/action_pack_assertions_test.rb b/actionpack/test/controller/action_pack_assertions_test.rb
index 5252e43c25..fab70c71d6 100644
--- a/actionpack/test/controller/action_pack_assertions_test.rb
+++ b/actionpack/test/controller/action_pack_assertions_test.rb
@@ -165,7 +165,7 @@ class ActionPackAssertionsControllerTest < ActionController::TestCase
match 'route_one', :to => 'action_pack_assertions#nothing', :as => :route_one
match ':controller/:action'
end
- set.install_helpers
+ set.install_helpers([ActionController::Base, ActionView::Base])
process :redirect_to_named_route
assert_redirected_to 'http://test.host/route_one'