Files
mozo-backend/spec/acceptance_steps/users/feedback_steps.rb
T
2015-09-17 17:46:33 +02:00

16 lines
484 B
Ruby

step "the user fills in the feedback field" do
js_set_field '.feedback-field', "Nice app!"
end
step "the user clicks on the submit feedback button" do
js_click ".submit-feedback-button"
end
step "the user should see the feedback submitted message" do
page.should have_content 'Thank you for your feedback'
end
step "a user feedback should be created containing the feedback" do
expect( UserFeedback.find_all_by_user_id_and_content(@user.id, 'Nice app!').size ).to eq 1
end