assert_redirected_to "/test"
end
+ def test_logout_fallback_without_referer
+ get :logout
+ assert_response :success
+ assert_template :logout
+ assert_select "input[name=referer][value=?]", ""
+ end
+
+ def test_logout_fallback_with_referer
+ get :logout, :params => { :referer => "/test" }
+ assert_response :success
+ assert_template :logout
+ assert_select "input[name=referer][value=?]", "/test"
+ end
+
def test_logout_with_token
token = create(:user).tokens.create