Created
March 31, 2013 20:23
-
-
Save BrianJoyce1/5281883 to your computer and use it in GitHub Desktop.
some test code
This file contains 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
require 'spec_helper' | |
describe User do | |
# pending "add some examples to (or delete) #{__FILE__}" | |
it "can login" do | |
user = FactoryGirl.create(:user) | |
visit '/login' | |
uri = URI.parse(current_url) | |
puts uri | |
fill_in 'email', :with => user.email | |
fill_in 'password', :with => user.password | |
click_button 'Login' | |
page.should have_content "Signed in successfully" | |
end | |
it "displays their email address" do | |
user = FactoryGirl.create(:user) | |
visit '/login' | |
puts "USER EMAIL IS: #{user.email}" | |
page.should have_content user.email | |
end | |
it "takes them to the home page" | |
it "shows their content" | |
it "shows the logout button" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment