diff options
authorintrigeri <>2019-12-15 09:05:30 +0000
committerintrigeri <>2019-12-15 09:05:30 +0000
commit5e7ff8e9e644374bea8120096706855bc3c1b5b2 (patch)
parent6d52c445043ba50143d0af7830b00299e5ca49c7 (diff)
Test suite: close communication channels with child processes before killing them (refs: #14948)bugfix/14948-avoid-zombies-in-testsuite-runs+force-all-tests
The "close" method ( "Closes ios and flushes any pending writes to the operating system". This could increase the chances that the child process we kill manages to exit (instead of being left as a zombie), by closing any communication channels we may have left open with it. But it's more likely that we get this expected benefit if we run .close before we kill that child process, to increase the success chances of whatever signal handler that child process has setup.
1 files changed, 1 insertions, 1 deletions
diff --git a/features/step_definitions/common_steps.rb b/features/step_definitions/common_steps.rb
index 1d5c107..36078ab 100644
--- a/features/step_definitions/common_steps.rb
+++ b/features/step_definitions/common_steps.rb
@@ -838,7 +838,7 @@ EOF
Process.kill(0, == 1
- add_after_scenario_hook { Process.kill("TERM",; proc.close }
+ add_after_scenario_hook { proc.close; Process.kill("TERM", }
# It seems necessary to actually check that the LAN server is
# serving, possibly because it isn't doing so reliably when setting