X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fselenium%2Fselenium.sh;h=f6bb944e0b144d0b05a64ca378576436397efde1;hb=2be1e039d9b45b91389a3bfd863b9638109afb82;hp=4a5c254839f07c47f821b06f31982b7d72459525;hpb=b4054da0f9c2a1c23f4af93871329e39c0ab6a8f;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/selenium/selenium.sh b/tests/selenium/selenium.sh index 4a5c254839..f6bb944e0b 100755 --- a/tests/selenium/selenium.sh +++ b/tests/selenium/selenium.sh @@ -3,10 +3,13 @@ set -euo pipefail # Check the command before running in background so # that it can actually fail and have a descriptive error hash chromedriver -chromedriver --url-base=/wd/hub --port=4444 & +chromedriver --url-base=wd/hub --port=4444 & +CHROME_DRIVER_PID=$! +echo chromedriver running with PID $CHROME_DRIVER_PID # Make sure it is killed to prevent file descriptors leak function kill_chromedriver() { - killall chromedriver > /dev/null + # Use kill instead of killall to increase chances of this working on Windows + kill $CHROME_DRIVER_PID > /dev/null } trap kill_chromedriver EXIT npm run selenium-test