Changeset 8216
- Timestamp:
- 11/26/07 22:41:28 (1 year ago)
- Files:
-
- trunk/actionpack/lib/action_controller/routing.rb (modified) (1 diff)
- trunk/actionpack/test/controller/routing_test.rb (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/actionpack/lib/action_controller/routing.rb
r8206 r8216 1013 1013 path = "#{path}/" unless path[-1] == ?/ 1014 1014 1015 path = "/#{options[:path_prefix]. gsub(/^\//,'')}#{path}" if options[:path_prefix]1015 path = "/#{options[:path_prefix].to_s.gsub(/^\//,'')}#{path}" if options[:path_prefix] 1016 1016 1017 1017 segments = segments_for_route_path(path) trunk/actionpack/test/controller/routing_test.rb
r8206 r8216 1995 1995 end 1996 1996 1997 def test_setting_root_in_namespace_using_symbol 1998 assert_nothing_raised do 1999 set.draw do |map| 2000 map.namespace :admin do |admin| 2001 admin.root :controller => 'home' 2002 end 2003 end 2004 end 2005 end 2006 2007 def test_setting_root_in_namespace_using_string 2008 assert_nothing_raised do 2009 set.draw do |map| 2010 map.namespace 'admin' do |admin| 2011 admin.root :controller => 'home' 2012 end 2013 end 2014 end 2015 end 2016 1997 2017 end 1998 2018