Skip to content
This repository has been archived by the owner on Nov 27, 2022. It is now read-only.

Commit

Permalink
[from now] 2014/04/15 15:02:20
Browse files Browse the repository at this point in the history
  • Loading branch information
mzp committed Apr 15, 2014
1 parent cb5a209 commit 1a35c5c
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions spec/controllers/authentication_controller_spec.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
require 'spec_helper'

describe AuthenticationController do
describe "get 'login'" do
before { get 'login' }
subject { response }
it { should redirect_to(root_path) }
end

describe "get 'logout'" do
before do
user = User.create!
user.save
sign_in user
end

describe 'response' do
before { get 'logout' }
subject { response }
it { should redirect_to(root_path) }
end

describe 'session' do
before { get 'logout' }
subject { controller.current_user }
it { should be_nil }
end
end
end

0 comments on commit 1a35c5c

Please sign in to comment.