1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/test/unit.rb (Test::Unit::Mini#run_test_suites): ensure

output sync mode to be restored.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29579 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2010-10-24 05:13:55 +00:00
parent 98ac9b8667
commit 071e1ba1f8
2 changed files with 14 additions and 2 deletions

View file

@ -1,3 +1,8 @@
Sun Oct 24 14:13:50 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/test/unit.rb (Test::Unit::Mini#run_test_suites): ensure
output sync mode to be restored.
Sun Oct 24 14:11:16 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* vm.c (vm_define_method): defined method is run with the default

View file

@ -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