From 6c906bf59111e09997787c1d4c5ba2ec2b783cdd Mon Sep 17 00:00:00 2001 From: Piotr Sarnacki Date: Wed, 1 Sep 2010 19:31:29 +0200 Subject: Use default_scope in isolated Engines to not force user to scope his routes --- railties/test/railties/engine_test.rb | 18 +++++++----------- railties/test/railties/mounted_engine_test.rb | 8 +++----- 2 files changed, 10 insertions(+), 16 deletions(-) (limited to 'railties/test') diff --git a/railties/test/railties/engine_test.rb b/railties/test/railties/engine_test.rb index 73d9b61719..3049011477 100644 --- a/railties/test/railties/engine_test.rb +++ b/railties/test/railties/engine_test.rb @@ -390,14 +390,12 @@ module RailtiesTest @plugin.write "config/routes.rb", <<-RUBY Bukkits::Engine.routes.draw do - scope(:module => :bukkits) do - match "/foo" => "foo#index", :as => "foo" - match "/foo/show" => "foo#show" - match "/from_app" => "foo#from_app" - match "/routes_helpers_in_view" => "foo#routes_helpers_in_view" - match "/polymorphic_path_without_namespace" => "foo#polymorphic_path_without_namespace" - resources :posts - end + match "/foo" => "foo#index", :as => "foo" + match "/foo/show" => "foo#show" + match "/from_app" => "foo#from_app" + match "/routes_helpers_in_view" => "foo#routes_helpers_in_view" + match "/polymorphic_path_without_namespace" => "foo#polymorphic_path_without_namespace" + resources :posts end RUBY @@ -514,9 +512,7 @@ module RailtiesTest @plugin.write "config/routes.rb", <<-RUBY Bukkits::Engine.routes.draw do - scope(:module => :bukkits) do - resources :posts - end + resources :posts end RUBY diff --git a/railties/test/railties/mounted_engine_test.rb b/railties/test/railties/mounted_engine_test.rb index 1df6326d26..b1e3e274b8 100644 --- a/railties/test/railties/mounted_engine_test.rb +++ b/railties/test/railties/mounted_engine_test.rb @@ -56,11 +56,9 @@ module ApplicationTests @plugin.write "config/routes.rb", <<-RUBY Blog::Engine.routes.draw do - scope(:module => :blog) do - resources :posts do - get :generate_application_route - get :application_route_in_view - end + resources :posts do + get :generate_application_route + get :application_route_in_view end end RUBY -- cgit v1.2.3