aboutsummaryrefslogtreecommitdiffstats
path: root/actionview
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2014-09-25 17:15:00 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2014-09-25 17:15:00 -0300
commitf82ecef9aef1798fa874c5104fef9d0dd072e757 (patch)
tree169e70a155f541d178a25b880cd265026ac76aaa /actionview
parentb98c593bc8ee21403018dca9a5a2885c7293c3fb (diff)
parent2d08fd250638a39fbc8509b4e1c3f87a5f9e36c6 (diff)
downloadrails-f82ecef9aef1798fa874c5104fef9d0dd072e757.tar.gz
rails-f82ecef9aef1798fa874c5104fef9d0dd072e757.tar.bz2
rails-f82ecef9aef1798fa874c5104fef9d0dd072e757.zip
Merge pull request #17058 from eval/issue-17057
Remove internal options from query string of paths
Diffstat (limited to 'actionview')
-rw-r--r--actionview/test/activerecord/polymorphic_routes_test.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/actionview/test/activerecord/polymorphic_routes_test.rb b/actionview/test/activerecord/polymorphic_routes_test.rb
index 4e94304796..5842b775bb 100644
--- a/actionview/test/activerecord/polymorphic_routes_test.rb
+++ b/actionview/test/activerecord/polymorphic_routes_test.rb
@@ -282,6 +282,15 @@ class PolymorphicRoutesTest < ActionController::TestCase
end
end
+ def test_regression_path_helper_prefixed_with_new_and_edit
+ with_test_routes do
+ assert_equal "/projects/new", new_polymorphic_path(@project)
+
+ @project.save
+ assert_equal "/projects/#{@project.id}/edit", edit_polymorphic_path(@project)
+ end
+ end
+
def test_url_helper_prefixed_with_edit
with_test_routes do
@project.save