Skip to content

Instantly share code, notes, and snippets.

@mockra
Last active August 29, 2015 14:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mockra/e26634d38eaaceeab712 to your computer and use it in GitHub Desktop.
Save mockra/e26634d38eaaceeab712 to your computer and use it in GitHub Desktop.
require 'spec_helper'
feature 'logging in' do
let(:user) { create :user }
scenario 'with correct credentials' do
visit login_path
fill_in 'session_email', with: user.email
fill_in 'session_password', with: user.password
click_button 'Log In'
within '.user-details' do
expect(page).to have_content user.email
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment