Sha256: a2158baef025adc0c92f0971ff81f867c5b5bda64c51816bba7afda6c2ef33ac

Contents?: true

Size: 701 Bytes

Versions: 17

Compression:

Stored size: 701 Bytes

Contents

require 'rails_helper'

feature 'user signs in', %Q{
  As a signed up user
  I want to sign in
  So that I can regain access to my account
} do
  scenario 'specify valid credentials' do
    user = FactoryBot.create(:user)

    visit new_user_session_path

    fill_in 'Email', with: user.email
    fill_in 'Password', with: user.password

    click_button 'Log in'

    expect(page).to have_content('Signed in successfully')
    expect(page).to have_content('Sign Out')
  end

  scenario 'specify invalid credentials' do
    visit new_user_session_path

    click_button 'Log in'
    expect(page).to have_content('Invalid Email or password')
    expect(page).to_not have_content('Sign Out')
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
make_it_so-0.6.0 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.5.1 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.5.0 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.4.5 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.4.3 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.4.2 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.4.1 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.4.0 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.3.8 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.3.7 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.3.6 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.3.5 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.3.4 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.2.4 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.2.3 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.1.4 templates/rails/spec/features/user_signs_in_spec.rb
make_it_so-0.1.3 templates/rails/spec/features/user_signs_in_spec.rb