From f21d6210eb3c24366136766c2557cf57fed81792 Mon Sep 17 00:00:00 2001 From: usa Date: Thu, 8 Aug 2013 06:42:05 +0000 Subject: [PATCH] * test/coverage/test_coverage.rb (TestCoverage#test_big_code): use `1' instead of `p' to get rid of a side effect. Kernel#p without any argument seems to do nothing, but flushes stdout. and, if stdout is redirected to file, fsync() will be called on Windows. so, when running test-all on Windows with redirection, such as CI environment, this test took a lot of time. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42439 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 9 +++++++++ test/coverage/test_coverage.rb | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 7bcbae00c6..438f12f27e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Thu Aug 8 15:37:53 2013 NAKAMURA Usaku + + * test/coverage/test_coverage.rb (TestCoverage#test_big_code): use `1' + instead of `p' to get rid of a side effect. + Kernel#p without any argument seems to do nothing, but flushes stdout. + and, if stdout is redirected to file, fsync() will be called on + Windows. so, when running test-all on Windows with redirection, such + as CI environment, this test took a lot of time. + Thu Aug 8 14:54:18 2013 Shugo Maeda * NEWS: add description of incompatibility introduced by r42396. diff --git a/test/coverage/test_coverage.rb b/test/coverage/test_coverage.rb index 4d785c3c0e..d9770c029b 100644 --- a/test/coverage/test_coverage.rb +++ b/test/coverage/test_coverage.rb @@ -47,7 +47,7 @@ class TestCoverage < Test::Unit::TestCase Dir.mktmpdir {|tmp| Dir.chdir(tmp) { File.open("test.rb", "w") do |f| - f.puts "p\n" * 10000 + f.puts "1\n" * 10000 f.puts "def ignore(x); end" f.puts "ignore([1" f.puts "])"