Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
23 lines (19 sloc) 718 Bytes
Given /^I am not authenticated$/ do
visit('/users/sign_out') # ensure that at least
Given /^I have one\s+user "([^\"]*)" with password "([^\"]*)" and login "([^\"]*)"$/ do |email, password, login| => email,
:login => login,
:password => password,
:password_confirmation => password).save!
Given /^I am a new, authenticated user$/ do
email = ''
login = 'Testing man'
password = 'secretpass'
Given %{I have one user "#{email}" with password "#{password}" and login "#{login}"}
And %{I go to login}
And %{I fill in "user_email" with "#{email}"}
And %{I fill in "user_password" with "#{password}"}
And %{I press "Sign in"}