Created
August 31, 2012 01:49
-
-
Save shirosaki/3547633 to your computer and use it in GitHub Desktop.
Fix test_pstore.rb to increase timeout
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/test/ruby/envutil.rb b/test/ruby/envutil.rb | |
index 19290c6..4fa037a 100644 | |
--- a/test/ruby/envutil.rb | |
+++ b/test/ruby/envutil.rb | |
@@ -74,12 +74,12 @@ module EnvUtil | |
return stdout, stderr, status | |
end | |
ensure | |
- [in_c, in_p, out_c, out_p, err_c, err_p].each do |io| | |
- io.close if io && !io.closed? | |
- end | |
[th_stdout, th_stderr].each do |th| | |
(th.kill; th.join) if th | |
end | |
+ [in_c, in_p, out_c, out_p, err_c, err_p].each do |io| | |
+ io.close if io && !io.closed? | |
+ end | |
end | |
module_function :invoke_ruby | |
diff --git a/test/test_pstore.rb b/test/test_pstore.rb | |
index 1b93925..ee66266 100644 | |
--- a/test/test_pstore.rb | |
+++ b/test/test_pstore.rb | |
@@ -120,7 +120,7 @@ class PStoreTest < Test::Unit::TestCase | |
def test_pstore_files_are_accessed_as_binary_files | |
bug5311 = '[ruby-core:39503]' | |
n = 128 | |
- assert_in_out_err(["-Eutf-8:utf-8", "-rpstore", "-", @pstore_file], <<-SRC, [bug5311], [], bug5311) | |
+ assert_in_out_err(["-Eutf-8:utf-8", "-rpstore", "-", @pstore_file], <<-SRC, [bug5311], [], bug5311, timeout: 15) | |
@pstore = PStore.new(ARGV[0]) | |
(1..#{n}).each do |i| | |
@pstore.transaction {@pstore["Key\#{i}"] = "value \#{i}"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment