Merge pull request #6097 from sjackman/test-pgrep
test: Avoid pgrep -q, not available with GNU pgrep
This commit is contained in:
commit
17d981777a
@ -33,7 +33,7 @@ rescue Exception => e # rubocop:disable Lint/RescueException
|
||||
error_pipe.puts e.to_json
|
||||
error_pipe.close
|
||||
pid = Process.pid.to_s
|
||||
if which("pgrep") && which("pkill") && system("pgrep", "-qP", pid)
|
||||
if which("pgrep") && which("pkill") && system("pgrep", "-P", pid, out: :close)
|
||||
$stderr.puts "Killing child processes..."
|
||||
system "pkill", "-P", pid
|
||||
sleep 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user