Permalink
Browse files

Fix problem with symbol/string mismatch on some routes

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1500 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent bb6b14b commit af33a6a6b193f4470d2c072d6fa197b72c74001b @jamis jamis committed Jun 24, 2005
@@ -115,7 +115,7 @@ def next_segment(assign_inline = false, default = nil)
end
code = "(#{code} || #{default.inspect})" if default
- return code
+ return code.to_s
end
def segment_name() "segment#{depth}".to_sym end
@@ -622,6 +622,13 @@ def test_time_generation
end
end
+ def test_route_with_colon_first
+ rs.draw do |map|
+ map.connect '/:controller/:action/:id', :action => 'index', :id => nil
+ map.connect ':url', :controller => 'tiny_url', :action => 'translate'
+ end
+ end
+
def test_basic_named_route
rs.home '', :controller => 'content', :action => 'list'
x = setup_for_named_route

0 comments on commit af33a6a

Please sign in to comment.