summaryrefslogtreecommitdiff
path: root/test/lib
diff options
context:
space:
mode:
Diffstat (limited to 'test/lib')
-rw-r--r--test/lib/leakchecker.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/lib/leakchecker.rb b/test/lib/leakchecker.rb
index 5d05c1e456..37c87c9f72 100644
--- a/test/lib/leakchecker.rb
+++ b/test/lib/leakchecker.rb
@@ -31,6 +31,9 @@ class LeakChecker
def check_fd_leak(test_name)
leaked = false
live1 = @fd_info
+ if IO.respond_to?(:console)
+ IO.console(:close)
+ end
live2 = find_fds
fd_closed = live1 - live2
if !fd_closed.empty?