diff options
| author | ryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-09-30 06:57:34 +0000 |
|---|---|---|
| committer | ryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-09-30 06:57:34 +0000 |
| commit | b06f8f299fb8ebb641163c071bba652afeed53f5 (patch) | |
| tree | 3eb1c9635cadbfef6795cca97d0396572c2e9627 /test/mini | |
| parent | 421d64a63a5b11994589277a46e99cbf680bf7e6 (diff) | |
| download | ruby-b06f8f299fb8ebb641163c071bba652afeed53f5.tar.gz ruby-b06f8f299fb8ebb641163c071bba652afeed53f5.tar.xz ruby-b06f8f299fb8ebb641163c071bba652afeed53f5.zip | |
Updated miniunit to 4257. This cleans all my tests when run in isolation. I still have failures when run with everything else
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19639 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/mini')
| -rw-r--r-- | test/mini/test_mini_test.rb | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/test/mini/test_mini_test.rb b/test/mini/test_mini_test.rb index 661c2965a..b7071f55a 100644 --- a/test/mini/test_mini_test.rb +++ b/test/mini/test_mini_test.rb @@ -9,11 +9,6 @@ require 'mini/test' Mini::Test.autorun -class Mini::Test - attr_accessor :test_count - attr_accessor :assertion_count -end - class TestMiniTest < Mini::Test::TestCase def setup @@ -47,13 +42,25 @@ class TestMiniTest < Mini::Test::TestCase BT_MIDDLE + ["./lib/mini/test.rb:29", "test/test_autotest.rb:422"]) + bt = util_expand_bt bt + ex = ["lib/autotest.rb:571:in `add_exception'", "test/test_autotest.rb:62:in `test_add_exception'"] + ex = util_expand_bt ex + fu = Mini::filter_backtrace(bt) assert_equal ex, fu end + def util_expand_bt bt + if RUBY_VERSION =~ /^1\.9/ then + bt.map { |f| (f =~ /^\./) ? File.expand_path(f) : f } + else + bt + end + end + def test_filter_backtrace_all_unit bt = (["./lib/mini/test.rb:165:in `__send__'"] + BT_MIDDLE + @@ -68,6 +75,9 @@ class TestMiniTest < Mini::Test::TestCase BT_MIDDLE + ["./lib/mini/test.rb:29", "-e:1"]) + + bt = util_expand_bt bt + ex = ["-e:1"] fu = Mini::filter_backtrace(bt) assert_equal ex, fu |
