mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-28 10:04:07 +01:00
Use RSpec 'expect' instead of 'should'
This commit is contained in:
parent
4ee8c2e7fd
commit
7a3f90a020
20 changed files with 208 additions and 248 deletions
|
|
@ -16,15 +16,15 @@ end
|
|||
|
||||
Then /the badge should show (.*)/ do |number|
|
||||
badge = find("span#badge_count").text.to_i
|
||||
badge.should == number.to_i
|
||||
expect(badge).to eq(number.to_i)
|
||||
end
|
||||
|
||||
Then(/^I should see an error flash message saying "([^"]*)"$/) do |message|
|
||||
xpath = "//div[@id='message_holder']/h4[@id='flash']"
|
||||
page.should have_xpath(xpath, :visible => true)
|
||||
expect(page).to have_xpath(xpath, :visible => true)
|
||||
|
||||
text = page.find(:xpath, xpath).text
|
||||
text.should == message
|
||||
expect(text).to eq(message)
|
||||
end
|
||||
|
||||
Then /^I should see "([^"]*)" $/ do |text|
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue