Created
June 4, 2010 00:00
-
-
Save zhengjia/424696 to your computer and use it in GitHub Desktop.
built-in webrat steps for cucumber cheatsheet
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
Given I am on "[page_name]" | |
When I go to "[page_name]" | |
When I press "[button]" | |
When I follow "[link]" | |
When I follow "[link]" within "[parent]" | |
When I fill in "[field]" with "[value]" | |
When I fill in "[value]" for "[field]" | |
When I fill in the following: | |
| field | value | | |
When I select "[value]" from "[field]" | |
When I select "[time]" as the date and time | |
When I select "[datetime]" as the "[datetime_label]" date and time | |
When I select "[time]" as the time | |
When I select "[time]" as the "[time_label]" time | |
When I select "[date]" as the date | |
When I select "[date]" as the "[date_label]" date | |
When I check "[field]" | |
When I uncheck "[field]" | |
When I choose "[field]" | |
When I attach the file at "[path]" to "[field]" | |
Then I should see "[text]/regex" | |
Then I should see "[text]/regex" within "[selector]" | |
Then I should not see "[text]/regex" | |
Then I should not see "[text]/regex" within "[selector]" | |
Then the "[field]" field should contain "[value]" | |
Then the "[field]" field should not contain "[value]" | |
Then the "[label]" checkbox should be checked | |
Then the "[label]" checkbox should not be checked | |
Then I should be on [page_name] | |
Then I should have the following query string: | |
Then show me the page | |
#modify from http://cheat.errtheblog.com/s/cucumber/ | |
# annother summary http://wiki.github.com/QuBiT/cucumber-netbeans-plugin/snippets-codetemplates |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment