diff --git a/test/controllers/sessions_controller_test.rb b/test/controllers/sessions_controller_test.rb index f1d6b65c9..74b336a4f 100644 --- a/test/controllers/sessions_controller_test.rb +++ b/test/controllers/sessions_controller_test.rb @@ -9,6 +9,15 @@ class SessionsControllerTest < ActionDispatch::IntegrationTest assert_response :success end + test "new redirects authenticated users" do + sign_in_as :kevin + + untenanted do + get new_session_path + assert_redirected_to root_url + end + end + test "create" do identity = identities(:kevin)