From d08e2f09db5ed7ec05527588efc8df7f1a2da96b Mon Sep 17 00:00:00 2001 From: Miles Gould Date: Wed, 21 Jan 2015 17:40:38 +0000 Subject: [PATCH] Add feature test for 500-on-follow error This doesn't actually catch the problem; I'm committing it so other people can see it and suggest ways of making it stronger. --- spec/features/following_spec.rb | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/spec/features/following_spec.rb b/spec/features/following_spec.rb index 35b74ce16..e0d998d86 100644 --- a/spec/features/following_spec.rb +++ b/spec/features/following_spec.rb @@ -47,6 +47,13 @@ feature "follows" do expect(page).to have_content "#{other_member.login_name}" end + scenario "does not die when passed an authenticity_token" do + visit member_follows_path( + member, + :params => {:authenticity_token => "Ultima ratio regum"}) + expect(page.status_code).to equal 200 + end + scenario "has correct message and follow button after unfollow" do click_link 'Follow' click_link 'Unfollow'