Skip to content

Commit

Permalink
Merge pull request #6784 from msgehard/active_support_cleanup
Browse files Browse the repository at this point in the history
Remove extra test case.
  • Loading branch information
carlosantoniodasilva committed Jun 19, 2012
2 parents b2ca26a + db03f13 commit 82cf95c
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions activesupport/test/clean_backtrace_test.rb
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ def setup
@bc.add_filter { |line| line.gsub("/my/prefix", '') } @bc.add_filter { |line| line.gsub("/my/prefix", '') }
end end


test "backtrace should not contain prefix when it has been filtered out" do test "backtrace should filter all lines in a backtrace, removing prefixes" do
assert_equal "/my/class.rb", @bc.clean([ "/my/prefix/my/class.rb" ]).first assert_equal \
["/my/class.rb", "/my/module.rb"],
@bc.clean(["/my/prefix/my/class.rb", "/my/prefix/my/module.rb"])
end end


test "backtrace cleaner should allow removing filters" do test "backtrace cleaner should allow removing filters" do
Expand All @@ -19,11 +21,6 @@ def setup
assert_equal "/my/other_prefix/my/class.rb", @bc.clean([ "/my/other_prefix/my/class.rb" ]).first assert_equal "/my/other_prefix/my/class.rb", @bc.clean([ "/my/other_prefix/my/class.rb" ]).first
end end


test "backtrace should filter all lines in a backtrace" do
assert_equal \
["/my/class.rb", "/my/module.rb"],
@bc.clean([ "/my/prefix/my/class.rb", "/my/prefix/my/module.rb" ])
end
end end


class BacktraceCleanerSilencerTest < ActiveSupport::TestCase class BacktraceCleanerSilencerTest < ActiveSupport::TestCase
Expand Down

0 comments on commit 82cf95c

Please sign in to comment.