diff --git a/lib/minitest/assertions.rb b/lib/minitest/assertions.rb index da07b00e..8941cebd 100644 --- a/lib/minitest/assertions.rb +++ b/lib/minitest/assertions.rb @@ -565,6 +565,11 @@ def capture_subprocess_io captured_stderr.unlink $stdout.reopen orig_stdout $stderr.reopen orig_stderr + + orig_stdout.close + orig_stderr.close + captured_stdout.close + captured_stderr.close end end end