Created
July 4, 2014 01:30
-
-
Save bricker/e97f4eafa8e5fd95e774 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe SessionsController do | |
| it "allows login with username" do | |
| user = User.create(username: "bricker", password: "test", password_confirmation: "test") | |
| post :create, username: "bricker", password: "test" | |
| controller.session[:user_id].should eq user.id | |
| end | |
| # same for e-mail | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment