Skip to content

Instantly share code, notes, and snippets.

@dscataglini
Created April 1, 2009 23:26
Show Gist options
  • Save dscataglini/88945 to your computer and use it in GitHub Desktop.
Save dscataglini/88945 to your computer and use it in GitHub Desktop.
it 'resets the session' do should_receive(:reset_session); logout_killing_session! end
it 'kills my auth_token cookie' do should_receive(:kill_remember_cookie!); logout_killing_session! end
it 'nils the current user' do logout_killing_session!; current_user.should be_nil end
it 'kills :user_id session' do
session.stub!(:[]=)
session.should_receive(:[]=).with(:user_id, nil).at_least(:once)
logout_killing_session!
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment