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): show the

result even when interrupted on the way.

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

View file

@ -1,4 +1,7 @@
Sun Oct 24 14:13:50 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
Sun Oct 24 14:17:58 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/test/unit.rb (Test::Unit::Mini#run_test_suites): show the
result even when interrupted on the way.
* lib/test/unit.rb (Test::Unit::Mini#run_test_suites): ensure
output sync mode to be restored.

View file

@ -165,6 +165,8 @@ module Test
def run_test_suites(*args)
old_sync = @@out.sync if @@out.respond_to?(:sync=)
super
rescue Interrupt
[@test_count, @assertion_count]
ensure
@@out.sync = old_sync if @@out.respond_to?(:sync=)
end