From 988513ac7a0cbd820c9486088256b8ab4e8acf74 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Thu, 30 Apr 2009 11:40:29 -0500 Subject: Framework backtrace cleaning is handled by ActiveSupport now --- actionpack/test/controller/test_test.rb | 27 --------------------------- 1 file changed, 27 deletions(-) (limited to 'actionpack/test/controller') diff --git a/actionpack/test/controller/test_test.rb b/actionpack/test/controller/test_test.rb index f68ffc7a2a..b372980242 100644 --- a/actionpack/test/controller/test_test.rb +++ b/actionpack/test/controller/test_test.rb @@ -629,33 +629,6 @@ XML end end -class CleanBacktraceTest < ActionController::TestCase - def test_should_reraise_the_same_object - exception = ActiveSupport::TestCase::Assertion.new('message') - clean_backtrace { raise exception } - rescue Exception => caught - assert_equal exception.object_id, caught.object_id - assert_equal exception.message, caught.message - end - - def test_should_clean_assertion_lines_from_backtrace - path = File.expand_path("#{File.dirname(__FILE__)}/../../lib/action_controller/testing") - exception = ActiveSupport::TestCase::Assertion.new('message') - exception.set_backtrace ["#{path}/abc", "#{path}/assertions/def"] - clean_backtrace { raise exception } - rescue Exception => caught - assert_equal ["#{path}/abc"], caught.backtrace - end - - def test_should_only_clean_assertion_failure_errors - clean_backtrace do - raise "can't touch this", [File.expand_path("#{File.dirname(__FILE__)}/../../lib/action_controller/assertions/abc")] - end - rescue => caught - assert !caught.backtrace.empty? - end -end - class InferringClassNameTest < ActionController::TestCase def test_determine_controller_class assert_equal ContentController, determine_class("ContentControllerTest") -- cgit v1.2.3