From 8fc5daeb3f0bc7adcc7e75746f98c0c4385ad6fa Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 30 Apr 2021 12:53:56 +0200 Subject: [PATCH] Use sapi/cli/php to run tests for faster failure (#6931) We always run test steps on azure, even if a previous step failed, because we don't want a failure in one configuration to prevent testing of other configurations. However, if building PHP fails in the first place, then we currently end up testing the system PHP binary. This is not only useless, but will also result in a test runner hang and cause the job to time out. Avoid this by using sapi/cli/php instead of the installed php as the test binary. If we fail to build, then it will not exist, and testing will fail immediately. --- azure/macos/test.yml | 2 +- azure/test.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/azure/macos/test.yml b/azure/macos/test.yml index f139e53e404..cc7db396604 100644 --- a/azure/macos/test.yml +++ b/azure/macos/test.yml @@ -9,7 +9,7 @@ steps: export SKIP_IO_CAPTURE_TESTS=1 export CI_NO_IPV6=1 rm -rf junit.xml | true - /usr/local/bin/php run-tests.php -P -q \ + sapi/cli/php run-tests.php -P -q \ -j$(sysctl -n hw.ncpu) \ -g FAIL,XFAIL,BORK,WARN,LEAK,XLEAK,SKIP \ --offline \ diff --git a/azure/test.yml b/azure/test.yml index 95fa7b4a096..f96075c20d0 100644 --- a/azure/test.yml +++ b/azure/test.yml @@ -17,7 +17,7 @@ steps: export SKIP_IO_CAPTURE_TESTS=1 export MSAN_SYMBOLIZER_PATH=/usr/lib/llvm-6.0/bin/llvm-symbolizer rm -rf junit.xml | true - php run-tests.php -P -q \ + sapi/cli/php run-tests.php -P -q \ -j$(/usr/bin/nproc) \ -g FAIL,XFAIL,BORK,WARN,LEAK,XLEAK,SKIP \ --offline \