Created
October 15, 2013 02:25
-
-
Save whitneyimura/6985610 to your computer and use it in GitHub Desktop.
Sample Step definitions for login
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.join(File.dirname(__FILE__), '..', '..', 'lib', 'pages', 'HomePage') | |
And /^I click login$/ do | |
@page.header.click_login | |
end | |
And /^I enter ([A-za-z0-9.@]+)$/ do |email| | |
@email = email | |
end | |
And /^password as (w+)$/ do |password| | |
@password = password | |
end | |
When /^I attempt to login$/ do | |
@page.header.login(@email, @password) | |
end | |
Then /^the login should (w+)$/ do |result| | |
@page.header.login_result_is(result) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment