diff options
| author | Michael Kozono <mkozono@gmail.com> | 2017-05-01 13:46:30 -0700 |
|---|---|---|
| committer | Michael Kozono <mkozono@gmail.com> | 2017-05-05 12:11:57 -0700 |
| commit | 7d02bcd2e0165a90a9f2c1edb34b064ff76afd69 (patch) | |
| tree | 3b74cbbf74fca3b36effa5ea4b33d8bd29e22f73 /spec/controllers/application_controller_spec.rb | |
| parent | f4a2dfb46f168d3fd7309aca8631cf680456fa82 (diff) | |
| download | gitlab-ce-7d02bcd2e0165a90a9f2c1edb34b064ff76afd69.tar.gz | |
Redirect from redirect routes to canonical routes
Diffstat (limited to 'spec/controllers/application_controller_spec.rb')
| -rw-r--r-- | spec/controllers/application_controller_spec.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/spec/controllers/application_controller_spec.rb b/spec/controllers/application_controller_spec.rb index 1bf0533ca24..d40aae04fc3 100644 --- a/spec/controllers/application_controller_spec.rb +++ b/spec/controllers/application_controller_spec.rb @@ -106,10 +106,9 @@ describe ApplicationController do controller.send(:route_not_found) end - it 'does redirect to login page if not authenticated' do + it 'does redirect to login page via authenticate_user! if not authenticated' do allow(controller).to receive(:current_user).and_return(nil) - expect(controller).to receive(:redirect_to) - expect(controller).to receive(:new_user_session_path) + expect(controller).to receive(:authenticate_user!) controller.send(:route_not_found) end end |
