aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/routing_tests.rb
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2005-03-20 14:04:33 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2005-03-20 14:04:33 +0000
commit37a46151ec14ae11f5306d997b822f30be7a69d3 (patch)
tree40d12bfc04ce9bd1bc90596ef966b5cc218f38f8 /actionpack/test/controller/routing_tests.rb
parentce9a9433b38b6f7dc024ec249cadc92a4ab4533c (diff)
downloadrails-37a46151ec14ae11f5306d997b822f30be7a69d3.tar.gz
rails-37a46151ec14ae11f5306d997b822f30be7a69d3.tar.bz2
rails-37a46151ec14ae11f5306d997b822f30be7a69d3.zip
Added path collection syntax for Routes that will gobble up the rest of the url and pass it on to the controller #830 [rayners]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@927 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/test/controller/routing_tests.rb')
-rw-r--r--actionpack/test/controller/routing_tests.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/actionpack/test/controller/routing_tests.rb b/actionpack/test/controller/routing_tests.rb
index d4f954e590..744ccb1093 100644
--- a/actionpack/test/controller/routing_tests.rb
+++ b/actionpack/test/controller/routing_tests.rb
@@ -325,6 +325,15 @@ class RouteTests < Test::Unit::TestCase
assert_equal Controllers::Admin::UserController, controller
assert_equal %w{action id}, leftovers
end
+
+ def test_path_collection
+ route '*path_info', :controller => 'content', :action => 'fish'
+ verify_recognize'path/with/slashes',
+ :controller => 'content', :action => 'fish', :path_info => 'path/with/slashes'
+ verify_generate('path/with/slashes', {},
+ {:controller => 'content', :action => 'fish', :path_info => 'path/with/slashes'},
+ {})
+ end
def test_special_characters
route ':id', :controller => 'content', :action => 'fish'