aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/dispatch/routing_test.rb
diff options
context:
space:
mode:
authorCarlhuda <carlhuda@engineyard.com>2010-02-24 16:01:03 -0800
committerCarlhuda <carlhuda@engineyard.com>2010-02-25 17:53:00 -0800
commit226dfc2681c98deaf14e4ae82e973d1d5caedd68 (patch)
treedf761036bb714f3b9c10bb1eced20322aad953a7 /actionpack/test/dispatch/routing_test.rb
parent76237f163ff7ad2a64af926030e3449c547cafa2 (diff)
downloadrails-226dfc2681c98deaf14e4ae82e973d1d5caedd68.tar.gz
rails-226dfc2681c98deaf14e4ae82e973d1d5caedd68.tar.bz2
rails-226dfc2681c98deaf14e4ae82e973d1d5caedd68.zip
WIP: Remove the global router
Diffstat (limited to 'actionpack/test/dispatch/routing_test.rb')
-rw-r--r--actionpack/test/dispatch/routing_test.rb10
1 files changed, 2 insertions, 8 deletions
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb
index e29127f78f..7cfc6ef3d7 100644
--- a/actionpack/test/dispatch/routing_test.rb
+++ b/actionpack/test/dispatch/routing_test.rb
@@ -164,6 +164,8 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest
Routes
end
+ include Routes.named_url_helpers
+
def test_logout
with_test_routes do
delete '/logout'
@@ -728,14 +730,6 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest
private
def with_test_routes
- real_routes, temp_routes = ActionDispatch::Routing::Routes, Routes
-
- ActionDispatch::Routing.module_eval { remove_const :Routes }
- ActionDispatch::Routing.module_eval { const_set :Routes, temp_routes }
-
yield
- ensure
- ActionDispatch::Routing.module_eval { remove_const :Routes }
- ActionDispatch::Routing.const_set(:Routes, real_routes)
end
end