aboutsummaryrefslogtreecommitdiffstats
path: root/test/ruby/test_process.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_process.rb')
-rw-r--r--test/ruby/test_process.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb
index 608d663027..0530c8d088 100644
--- a/test/ruby/test_process.rb
+++ b/test/ruby/test_process.rb
@@ -1965,4 +1965,12 @@ EOS
runner.close
end
end if defined?(fork)
+
+ def test_process_detach
+ pid = fork {}
+ th = Process.detach(pid)
+ assert_equal pid, th.pid
+ status = th.value
+ assert status.success?, status.inspect
+ end if defined?(fork)
end