Created
November 2, 2009 09:15
-
-
Save kornysietsma/224045 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 the Twitter home page" do | |
@home_page.visit | |
end | |
Given "I see the most popular topic" do | |
@most_popular = @home_page.most_popular_topic | |
puts "Most popular topic: '#{@most_popular}'" | |
end | |
When "I visit the Twitter home page" do | |
Given "I am on the Twitter home page" | |
end | |
When "I search for the most popular topic" do | |
@home_page.search(@most_popular) | |
end | |
Then "I should be able to see popular topics right now" do | |
@home_page.should have_popular_topics | |
end | |
Then "I should see results containing the most popular topic" do | |
@results_page.tweets.each {|result| result[:tweet].downcase.should include @most_popular.downcase} | |
end | |
Then /^I should see a message indicating more results exist within (\d+) seconds$/ do |timeout| | |
@results_page.wait_for_more_results(timeout.to_i) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment