Fix RSpec's should deprecation warning

Using `stub` from rspec-mocks' old `:should` syntax without explicitly
enabling the syntax is deprecated. Use the new `:expect` syntax or
explicitly enable `:should` instead
This commit is contained in:
rgarcia
2018-01-16 00:00:52 +01:00
parent 398cdd2d4c
commit 8fb9be9d07

View File

@@ -29,7 +29,7 @@ feature "Voter" do
expect(page).not_to have_link(answer_yes.title)
end
expect(find(:css, ".js-token-message")).to be_visible
expect(page).to have_css(".js-token-message", visible: true)
token = find(:css, ".js-question-answer")[:href].gsub(/.+?(?=token)/, '').gsub('token=', '')
expect(page).to have_content "You can write down this vote identifier, to check your vote on the final results: #{token}"