From 180eb8ff31d679e6b0ddd55c610139c38ec52f18 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Fri, 6 Jan 2012 10:42:26 -0800 Subject: no need for assert_block --- actionpack/lib/action_dispatch/testing/assertions/response.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'actionpack/lib') diff --git a/actionpack/lib/action_dispatch/testing/assertions/response.rb b/actionpack/lib/action_dispatch/testing/assertions/response.rb index fbee226a36..b3d34faf9c 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/response.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/response.rb @@ -29,11 +29,11 @@ module ActionDispatch validate_request! if type.in?([:success, :missing, :redirect, :error]) && @response.send("#{type}?") - assert_block("") { true } # to count the assertion + assert true # to count the assertion elsif type.is_a?(Fixnum) && @response.response_code == type - assert_block("") { true } # to count the assertion + assert true # to count the assertion elsif type.is_a?(Symbol) && @response.response_code == Rack::Utils::SYMBOL_TO_STATUS_CODE[type] - assert_block("") { true } # to count the assertion + assert true # to count the assertion else flunk "Expected response to be a <#{type}>, but was <#{@response.response_code}>" end -- cgit v1.2.3