aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre Schambacher <pschambacher@zendesk.com>2016-02-01 11:28:25 +0000
committerPierre Schambacher <pschambacher@zendesk.com>2016-02-01 11:51:45 +0000
commitc3639458af5e307191ff9d5674f8144caf6a2833 (patch)
tree1befa7f3d07ac1d9b8cb87144db49b3ffeb64d99
parent407baa2b4cc462e42c9aaccc9850adad4462ea7e (diff)
downloadrails-c3639458af5e307191ff9d5674f8144caf6a2833.tar.gz
rails-c3639458af5e307191ff9d5674f8144caf6a2833.tar.bz2
rails-c3639458af5e307191ff9d5674f8144caf6a2833.zip
Duplicate assert_generates options before modifying it
-rw-r--r--actionpack/lib/action_dispatch/testing/assertions/routing.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/testing/assertions/routing.rb b/actionpack/lib/action_dispatch/testing/assertions/routing.rb
index 78ef860548..e7af27463c 100644
--- a/actionpack/lib/action_dispatch/testing/assertions/routing.rb
+++ b/actionpack/lib/action_dispatch/testing/assertions/routing.rb
@@ -86,6 +86,7 @@ module ActionDispatch
end
# Load routes.rb if it hasn't been loaded.
+ options = options.clone
generated_path, query_string_keys = @routes.generate_extras(options, defaults)
found_extras = options.reject { |k, _| ! query_string_keys.include? k }