aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/redirect_test.rb
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2007-10-16 05:07:23 +0000
committerJeremy Kemper <jeremy@bitsweat.net>2007-10-16 05:07:23 +0000
commit5cb6a9aabdd2d74b7c8b52828f6b4797714ce78b (patch)
tree1b9b3536354a9afb6c141ae1ffa35fef8c6af957 /actionpack/test/controller/redirect_test.rb
parentcfe36d16097ba6c4e64d91026aef02bca25f73db (diff)
downloadrails-5cb6a9aabdd2d74b7c8b52828f6b4797714ce78b.tar.gz
rails-5cb6a9aabdd2d74b7c8b52828f6b4797714ce78b.tar.bz2
rails-5cb6a9aabdd2d74b7c8b52828f6b4797714ce78b.zip
Improve the error message for assert_redirected_to. Closes #7337 [mikong, sandofsky]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7934 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/test/controller/redirect_test.rb')
-rwxr-xr-xactionpack/test/controller/redirect_test.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/test/controller/redirect_test.rb b/actionpack/test/controller/redirect_test.rb
index 7ab1ddde0c..4a3b8254aa 100755
--- a/actionpack/test/controller/redirect_test.rb
+++ b/actionpack/test/controller/redirect_test.rb
@@ -162,11 +162,11 @@ class RedirectTest < Test::Unit::TestCase
begin
assert_redirected_to :action => "other_host", :only_path => true
rescue Test::Unit::AssertionFailedError => err
- redirection_msg, diff_msg = err.message.scan(/<\{[^\}]+\}>/).collect { |s| s[2..-3] }
+ expected_msg, redirection_msg, diff_msg = err.message.scan(/<\{[^\}]+\}>/).collect { |s| s[2..-3] }
assert_match %r("only_path"=>false), redirection_msg
assert_match %r("host"=>"other.test.host"), redirection_msg
assert_match %r("action"=>"other_host"), redirection_msg
- assert_match %r("only_path"=>true), diff_msg
+ assert_match %r("only_path"=>false), diff_msg
assert_match %r("host"=>"other.test.host"), diff_msg
end
end