From 37d4415a7b433fcb987b1c6a5b51bf2d8efc5d5e Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Wed, 7 May 2014 10:18:18 -0700 Subject: test for inconsistency between String and Symbol url_for handling --- actionview/test/activerecord/polymorphic_routes_test.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'actionview/test/activerecord/polymorphic_routes_test.rb') diff --git a/actionview/test/activerecord/polymorphic_routes_test.rb b/actionview/test/activerecord/polymorphic_routes_test.rb index b9040d5e39..a42888d873 100644 --- a/actionview/test/activerecord/polymorphic_routes_test.rb +++ b/actionview/test/activerecord/polymorphic_routes_test.rb @@ -81,7 +81,10 @@ class PolymorphicRoutesTest < ActionController::TestCase def test_string with_test_routes do + # FIXME: why are these different? Symbol case passes through to + # `polymorphic_url`, but the String case doesn't. assert_equal "http://example.com/projects", polymorphic_url("projects") + assert_equal "projects", url_for("projects") end end @@ -94,6 +97,7 @@ class PolymorphicRoutesTest < ActionController::TestCase def test_symbol with_test_routes do assert_equal "http://example.com/projects", polymorphic_url(:projects) + assert_equal "http://example.com/projects", url_for(:projects) end end -- cgit v1.2.3