From 01d17943ec27e762141209bdbcaf73446a272fcc Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Fri, 6 Jan 2012 11:20:26 -0800 Subject: test response assertions --- actionpack/lib/action_dispatch/testing/assertions/response.rb | 8 -------- 1 file changed, 8 deletions(-) (limited to 'actionpack/lib/action_dispatch/testing') diff --git a/actionpack/lib/action_dispatch/testing/assertions/response.rb b/actionpack/lib/action_dispatch/testing/assertions/response.rb index b3d34faf9c..84c2ae716c 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/response.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/response.rb @@ -26,8 +26,6 @@ module ActionDispatch # assert_response 401 # def assert_response(type, message = nil) - validate_request! - if type.in?([:success, :missing, :redirect, :error]) && @response.send("#{type}?") assert true # to count the assertion elsif type.is_a?(Fixnum) && @response.response_code == type @@ -85,12 +83,6 @@ module ActionDispatch @controller.url_for(fragment) end.gsub(/[\r\n]/, '') end - - def validate_request! - unless @request.is_a?(ActionDispatch::Request) - raise ArgumentError, "@request must be an ActionDispatch::Request" - end - end end end end -- cgit v1.2.3