diff options
author | Seb Bacon <seb.bacon@gmail.com> | 2012-01-12 08:39:35 +0000 |
---|---|---|
committer | Seb Bacon <seb.bacon@gmail.com> | 2012-01-12 08:39:35 +0000 |
commit | be9aa2c2d19199084e12d6318feeb48db2287331 (patch) | |
tree | e0313baac660357d76d04a8a1ff0137fe09961fc /spec/controllers/user_controller_spec.rb | |
parent | 48de103eaa2564a88369f1abdb8a7d1ab79e50d5 (diff) |
Accounts using expired PostRedirects were still causing 500 errors. Fixes #334 (again)
Diffstat (limited to 'spec/controllers/user_controller_spec.rb')
-rw-r--r-- | spec/controllers/user_controller_spec.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/controllers/user_controller_spec.rb b/spec/controllers/user_controller_spec.rb index 2560b48c7..30ad61706 100644 --- a/spec/controllers/user_controller_spec.rb +++ b/spec/controllers/user_controller_spec.rb @@ -111,15 +111,16 @@ describe UserController, "when signing in" do it "should not log you in if you use an invalid PostRedirect token, and shouldn't give 500 error either" do ActionController::Routing::Routes.filters.clear - get :signin, :r => "/list" - response.should render_template('sign') post_redirect = "something invalid" lambda { post :signin, { :user_signin => { :email => 'bob@localhost', :password => 'jonespassword' }, :token => post_redirect } }.should_not raise_error(NoMethodError) + post :signin, { :user_signin => { :email => 'bob@localhost', :password => 'jonespassword' }, + :token => post_redirect } response.should render_template('sign') + assigns[:post_redirect].should == nil end # No idea how to test this in the test framework :( |