1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

test for inconsistency between String and Symbol url_for handling

This commit is contained in:
Aaron Patterson 2014-05-07 10:18:18 -07:00
parent bfcbd6fd4c
commit 37d4415a7b

View file

@ -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