Permalink
Browse files

Added tests for Welcome msg after signin

  • Loading branch information...
1 parent dc1be7c commit 6a57fbdaed04115d8934bd08e7dfc2cab2c13b81 @YogiZoli committed Apr 8, 2012
Showing with 9 additions and 0 deletions.
  1. +9 −0 spec/requests/user_pages_spec.rb
@@ -41,6 +41,15 @@
click_button "Create my account"
end.to change(User, :count).by(1)
end
+
+ describe "after saving the user" do
+ before { click_button submit }
+ let(:user) { User.find_by_email('user@example.com') }
+
+ it { should have_selector('title', text: user.name) }
+ it { should have_selector('div.alert.alert-success', text: 'Welcome') }
+ end
+
end
end

0 comments on commit 6a57fbd

Please sign in to comment.