mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-31 14:28:49 +01:00
if you want to run it, update your database.yml to include cucumber and selenium environments (like in the .tmpl) and run RAILS_ENV=selenium cucumber -p selenium
14 lines
488 B
Ruby
14 lines
488 B
Ruby
Given /^I have logged in as "(.*)" with password "(.*)"$/ do |username, password|
|
|
visit login_path
|
|
fill_in "Login", :with => username
|
|
fill_in "Password", :with => password
|
|
click_button
|
|
response.should contain(/Login successful/)
|
|
@current_user = User.find_by_login(username)
|
|
end
|
|
|
|
When /^I submit the login form as user "([^\"]*)" with password "([^\"]*)"$/ do |username, password|
|
|
fill_in 'Login', :with => username
|
|
fill_in 'Password', :with => password
|
|
click_button
|
|
end
|