Improve performance of AppVeyor test runs

We only load a minimum set of extensions, and rely on dynamic loading
of others due to `--EXTENSION--` triggers.  We do not run the imap,
ldap and snmp test suites, because most of the tests would be skipped
after timeouts anyway.

Closes GH-7150.
This commit is contained in:
Christoph M. Becker 2021-06-14 18:39:03 +02:00
parent 859524c246
commit 139a73b5a4
No known key found for this signature in database
GPG Key ID: D66C9593118BCCB6
4 changed files with 20 additions and 10 deletions

View File

@ -51,11 +51,6 @@ 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
rem the following exts are tested via --EXTENSIONS--; update as necessary
set EXT_EXCLUDE_FROM_TEST=bz2,exif,fileinfo,ffi,ftp,gd,gmp,soap,sodium,sqlite3,tidy,%EXT_EXCLUDE_FROM_TEST%
if "%OPCACHE%" equ "0" set EXT_EXCLUDE_FROM_TEST=%EXT_EXCLUDE_FROM_TEST%,opcache
set CFLAGS=/W1 /WX
cmd /c configure.bat ^
@ -66,7 +61,7 @@ cmd /c configure.bat ^
--enable-object-out-dir=%PHP_BUILD_OBJ_DIR% ^
--with-php-build=%DEPS_DIR% ^
%ADD_CONF% ^
--with-test-ini-ext-exclude=%EXT_EXCLUDE_FROM_TEST%
--disable-test-ini
if %errorlevel% neq 0 exit /b 3
nmake /NOLOGO

View File

@ -89,9 +89,23 @@ if not exist "%PHP_BUILD_CACHE_ENCHANT_DICT_DIR%\en_US.aff" (
mkdir %LOCALAPPDATA%\enchant\hunspell
copy %PHP_BUILD_CACHE_ENCHANT_DICT_DIR%\* %LOCALAPPDATA%\enchant\hunspell
set TEST_PHPDBG_EXECUTABLE=%PHP_BUILD_OBJ_DIR%\Release
if "%THREAD_SAFE%" equ "1" set TEST_PHPDBG_EXECUTABLE=%TEST_PHPDBG_EXECUTABLE%_TS
set TEST_PHPDBG_EXECUTABLE=%TEST_PHPDBG_EXECUTABLE%\phpdbg.exe
set PHP_BUILD_DIR=%PHP_BUILD_OBJ_DIR%\Release
if "%THREAD_SAFE%" equ "1" set PHP_BUILD_DIR=%PHP_BUILD_DIR%_TS
mkdir %PHP_BUILD_DIR%\test_file_cache
rem generate php.ini
echo extension_dir=%PHP_BUILD_DIR% > %PHP_BUILD_DIR%\php.ini
echo opcache.file_cache=%PHP_BUILD_DIR%\test_file_cache >> %PHP_BUILD_DIR%\php.ini
if "%OPCACHE%" equ "1" echo zend_extension=php_opcache.dll >> %PHP_BUILD_DIR%\php.ini
rem work-around for some spawned PHP processes requiring OpenSSL
echo extension=php_openssl.dll >> %PHP_BUILD_DIR%\php.ini
rem remove ext dlls for which tests are not supported
for %%i in (imap ldap oci8_12c pdo_firebird pdo_oci snmp) do (
del %PHP_BUILD_DIR%\php_%%i.dll
)
set TEST_PHPDBG_EXECUTABLE=%PHP_BUILD_DIR%\phpdbg.exe
mkdir c:\tests_tmp

View File

@ -9,7 +9,7 @@ com_dotnet
$php = PHP_BINARY;
$ini = php_ini_loaded_file();
$iniopt = $ini ? "-c $ini" : '';
$command = "$php $iniopt -d com.autoregister_typelib=1 -r \"new COM('WbemScripting.SWbemLocator');\"";
$command = "$php $iniopt -d extension=com_dotnet -d com.autoregister_typelib=1 -r \"new COM('WbemScripting.SWbemLocator');\"";
exec($command, $output, $status);
var_dump($output, $status);
?>

View File

@ -1,6 +1,7 @@
--TEST--
Bug #68547 (Exif Header component value check error)
--EXTENSIONS--
mbstring
exif
--FILE--
<?php