summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/test/unit.rb11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/test/unit.rb b/lib/test/unit.rb
index f722205fa4..b5b9f719b1 100644
--- a/lib/test/unit.rb
+++ b/lib/test/unit.rb
@@ -156,11 +156,18 @@ module Test
def self.autorun
at_exit {
Test::Unit::RunCount.run_once {
- exit(Test::Unit::Mini.new.run(ARGV) || true)
- }
+ exit(Test::Unit::Mini.new.run(ARGV) || true)
+ }
} unless @@installed_at_exit
@@installed_at_exit = true
end
+
+ def run_test_suites(*args)
+ old_sync = @@out.sync if @@out.respond_to?(:sync=)
+ super
+ ensure
+ @@out.sync = old_sync if @@out.respond_to?(:sync=)
+ end
end
end
end