login.rb 349 B

12345678910111213
  1. Given(/^I am on Karmen homepage$/) do
  2. visit 'http://karmen:3000/login'
  3. end
  4. When(/^I fill the form with username and password$/) do
  5. fill_in('username', with: 'andrea.fazzi')
  6. fill_in('password', with: 'test123')
  7. click_button('Login')
  8. end
  9. Then(/^I should gain access to the application$/) do
  10. expect(page).to have_content 'Super-secret'
  11. end