From c5b08df597d917768250fb1185e252e7ab2e4f72 Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sun, 16 May 2021 16:55:28 +0200 Subject: [PATCH 1/2] Adjust run-tests.php to dynamic extension loading PR #6787 changed the behavior of the `--EXTENSIONS--` section, so that not yet loaded extensions are dynamically loaded if possible. However, when no tests are specified for the runner, only tests for already loaded extensions are run, what defeats the purpose of the improvement of the `--EXTENSIONS--` behavior. We cater to that by detecting loadable extensions, and also run their tests. --- run-tests.php | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/run-tests.php b/run-tests.php index 3c7189b24d20..8fea2cf9e77f 100755 --- a/run-tests.php +++ b/run-tests.php @@ -860,9 +860,22 @@ function write_information(): void } @unlink($info_file); - // load list of enabled extensions - save_text($info_file, - ''); + // load list of enabled and loadable extensions + save_text($info_file, <<<'PHP' + + PHP); $exts_to_test = explode(',', `$php $pass_options $info_params $no_file_cache "$info_file"`); // check for extensions that need special handling and regenerate $info_params_ex = [ From 5f095525709029870ef4a48598779154d4d75ea3 Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sun, 16 May 2021 16:59:34 +0200 Subject: [PATCH 2/2] Don't add unnecessary extensions to the test INI for AppVeyor Several extension test suites have already been changed to rely on the new behavior of `--EXTENSIONS--` section, i.e. to dynamically load required extensions on demand. Thus, there is no need to load these extensions always, which should improve the performance of executing the tests. --- appveyor/build_task.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/appveyor/build_task.bat b/appveyor/build_task.bat index 91fedae85537..6e7096a84227 100644 --- a/appveyor/build_task.bat +++ b/appveyor/build_task.bat @@ -51,7 +51,7 @@ if %errorlevel% neq 0 exit /b 3 if "%THREAD_SAFE%" equ "0" set ADD_CONF=%ADD_CONF% --disable-zts if "%INTRINSICS%" neq "" set ADD_CONF=%ADD_CONF% --enable-native-intrinsics=%INTRINSICS% -set EXT_EXCLUDE_FROM_TEST=snmp,oci8_12c,pdo_oci,pdo_firebird,ldap,imap,ftp +set EXT_EXCLUDE_FROM_TEST=bz2,exif,fileinfo,ffi,ftp,gmp,imap,ldap,oci8_12c,pdo_firebird,pdo_oci,snmp,soap,sodium,sqlite3,tidy if "%OPCACHE%" equ "0" set EXT_EXCLUDE_FROM_TEST=%EXT_EXCLUDE_FROM_TEST%,opcache set CFLAGS=/W1 /WX