diff options
author | Godfrey Chan <godfreykfc@gmail.com> | 2014-11-10 00:30:08 -0800 |
---|---|---|
committer | Godfrey Chan <godfreykfc@gmail.com> | 2014-11-10 00:31:49 -0800 |
commit | aa6637d140c2ebd28bbd23fc250af033a065dbe8 (patch) | |
tree | 547015bc9079ccbff588d6968d804de5b9019ce5 /actionpack/lib | |
parent | 52c3a16fa07cde643af3c2200e4b87bcb470eb12 (diff) | |
download | rails-aa6637d140c2ebd28bbd23fc250af033a065dbe8.tar.gz rails-aa6637d140c2ebd28bbd23fc250af033a065dbe8.tar.bz2 rails-aa6637d140c2ebd28bbd23fc250af033a065dbe8.zip |
Pass the route name explicitly
Follow up to 212057b9. Since that commit, we need to pass the `route_name`
explicitly. This is one of the left-over cases that was not handled in that
commit, which was causing `use_route` to be ignored in functional tests.
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_controller/test_case.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/test_case.rb b/actionpack/lib/action_controller/test_case.rb index 41d33d4396..aa475dc4c4 100644 --- a/actionpack/lib/action_controller/test_case.rb +++ b/actionpack/lib/action_controller/test_case.rb @@ -710,7 +710,8 @@ module ActionController :relative_url_root => nil, :_recall => @request.path_parameters) - url, query_string = @routes.path_for(options).split("?", 2) + route_name = options.delete :use_route + url, query_string = @routes.path_for(options, route_name).split("?", 2) @request.env["SCRIPT_NAME"] = @controller.config.relative_url_root @request.env["PATH_INFO"] = url |