From 0b55ce7191b167d67ec7ccc7eb8db2e5fac4f2e1 Mon Sep 17 00:00:00 2001 From: Marcel Molina Date: Mon, 26 Dec 2005 19:40:14 +0000 Subject: Value of full_messages on stubbed out AR instances should be an Array. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3352 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/lib/action_controller/assertions.rb | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'actionpack/lib') diff --git a/actionpack/lib/action_controller/assertions.rb b/actionpack/lib/action_controller/assertions.rb index 999edc1440..baf36f768d 100644 --- a/actionpack/lib/action_controller/assertions.rb +++ b/actionpack/lib/action_controller/assertions.rb @@ -309,12 +309,10 @@ module Test #:nodoc: end def clean_backtrace(&block) - begin - yield - rescue AssertionFailedError => e - path = File.expand_path(__FILE__) - raise AssertionFailedError, e.message, e.backtrace.reject { |line| File.expand_path(line) =~ /#{path}/ } - end + yield + rescue AssertionFailedError => e + path = File.expand_path(__FILE__) + raise AssertionFailedError, e.message, e.backtrace.reject { |line| File.expand_path(line) =~ /#{path}/ } end end end -- cgit v1.2.3