aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2007-09-24 23:12:25 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2007-09-24 23:12:25 +0000
commitbdf5672077f095dda577b10185e395f865aac3f6 (patch)
treebb99d1b2069d7a4418775dd954883630c433309d /actionpack/test
parente70bb8031f17c113810aa334aa524b2ed34cbb5f (diff)
downloadrails-bdf5672077f095dda577b10185e395f865aac3f6.tar.gz
rails-bdf5672077f095dda577b10185e395f865aac3f6.tar.bz2
rails-bdf5672077f095dda577b10185e395f865aac3f6.zip
Change from InvalidToken to InvalidAuthenticityToken to be more specific
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7623 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/test')
-rw-r--r--actionpack/test/controller/request_forgery_protection_test.rb24
1 files changed, 12 insertions, 12 deletions
diff --git a/actionpack/test/controller/request_forgery_protection_test.rb b/actionpack/test/controller/request_forgery_protection_test.rb
index 59df4615c5..98ca44c8cb 100644
--- a/actionpack/test/controller/request_forgery_protection_test.rb
+++ b/actionpack/test/controller/request_forgery_protection_test.rb
@@ -51,27 +51,27 @@ class RequestForgeryProtectionControllerTest < Test::Unit::TestCase
end
def test_should_not_allow_post_without_token
- assert_raises(ActionController::InvalidToken) { post :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { post :index }
end
def test_should_not_allow_put_without_token
- assert_raises(ActionController::InvalidToken) { put :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { put :index }
end
def test_should_not_allow_delete_without_token
- assert_raises(ActionController::InvalidToken) { delete :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { delete :index }
end
def test_should_not_allow_xhr_post_without_token
- assert_raises(ActionController::InvalidToken) { xhr :post, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :post, :index }
end
def test_should_not_allow_xhr_put_without_token
- assert_raises(ActionController::InvalidToken) { xhr :put, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :put, :index }
end
def test_should_not_allow_xhr_delete_without_token
- assert_raises(ActionController::InvalidToken) { xhr :delete, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :delete, :index }
end
def test_should_allow_post_with_token
@@ -161,27 +161,27 @@ class CsrfCookieMonsterControllerTest < Test::Unit::TestCase
end
def test_should_not_allow_post_without_token
- assert_raises(ActionController::InvalidToken) { post :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { post :index }
end
def test_should_not_allow_put_without_token
- assert_raises(ActionController::InvalidToken) { put :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { put :index }
end
def test_should_not_allow_delete_without_token
- assert_raises(ActionController::InvalidToken) { delete :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { delete :index }
end
def test_should_not_allow_xhr_post_without_token
- assert_raises(ActionController::InvalidToken) { xhr :post, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :post, :index }
end
def test_should_not_allow_xhr_put_without_token
- assert_raises(ActionController::InvalidToken) { xhr :put, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :put, :index }
end
def test_should_not_allow_xhr_delete_without_token
- assert_raises(ActionController::InvalidToken) { xhr :delete, :index }
+ assert_raises(ActionController::InvalidAuthenticityToken) { xhr :delete, :index }
end
def test_should_allow_post_with_token