summaryrefslogtreecommitdiff
path: root/users/test/functional/application_controller_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'users/test/functional/application_controller_test.rb')
-rw-r--r--users/test/functional/application_controller_test.rb7
1 files changed, 3 insertions, 4 deletions
diff --git a/users/test/functional/application_controller_test.rb b/users/test/functional/application_controller_test.rb
index 69bcb2f..857bae5 100644
--- a/users/test/functional/application_controller_test.rb
+++ b/users/test/functional/application_controller_test.rb
@@ -8,20 +8,19 @@ class ApplicationControllerTest < ActionController::TestCase
end
def test_authorize_redirect
- stub_logged_out
@controller.send(:authorize)
assert_access_denied
end
def test_authorized
- @user = stub_logged_in
+ login
@controller.send(:authorize)
assert_access_denied(false)
end
def test_authorize_admin
- @user = stub_logged_in
- @user.expects(:is_admin?).returns(false)
+ login
+ @current_user.expects(:is_admin?).returns(false)
@controller.send(:authorize_admin)
assert_access_denied
end