Skip to content

Commit e86acb1

Browse files
committed
Run POD_Firebird tests on AppVeyor CI
We also fix gh8626.phpt for the firebird driver by allowing negative status codes as well. We mark the other two test cases as xfail for the firebird driver for now. Closes GH-8666.
1 parent 13e46a0 commit e86acb1

File tree

4 files changed

+18
-2
lines changed

4 files changed

+18
-2
lines changed

appveyor/test_task.bat

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,20 @@ set ODBC_TEST_PASS=Password12!
4646
set ODBC_TEST_DSN=Driver={ODBC Driver 13 for SQL Server};Server=(local)\SQL2017;Database=master;uid=%ODBC_TEST_USER%;pwd=%ODBC_TEST_PASS%
4747
set PDOTEST_DSN=odbc:%ODBC_TEST_DSN%
4848

49+
rem setup Firebird related exts
50+
curl -sLo Firebird.zip https://github.com/FirebirdSQL/firebird/releases/download/v3.0.9/Firebird-3.0.9.33560-0_x64.zip
51+
7z x -oC:\Firebird Firebird.zip
52+
set PDO_FIREBIRD_TEST_DATABASE=C:\test.fdb
53+
set PDO_FIREBIRD_TEST_DSN=firebird:dbname=%PDO_FIREBIRD_TEST_DATABASE%
54+
set PDO_FIREBIRD_TEST_USER=SYSDBA
55+
set PDO_FIREBIRD_TEST_PASS=phpfi
56+
echo create database '%PDO_FIREBIRD_TEST_DATABASE%' user '%PDO_FIREBIRD_TEST_USER%' password '%PDO_FIREBIRD_TEST_PASS%';> C:\Firebird\setup.sql
57+
C:\Firebird\instsvc.exe install -n TestInstance
58+
C:\Firebird\isql -q -i C:\Firebird\setup.sql
59+
C:\Firebird\instsvc.exe start -n TestInstance
60+
if %errorlevel% neq 0 exit /b 3
61+
path C:\Firebird;%PATH%
62+
4963
rem prepare for ext/openssl
5064
if "%APPVEYOR%" equ "True" rmdir /s /q C:\OpenSSL-Win32 >NUL 2>NUL
5165
if "%APPVEYOR%" equ "True" rmdir /s /q C:\OpenSSL-Win64 >NUL 2>NUL
@@ -111,7 +125,7 @@ rem work-around for some spawned PHP processes requiring OpenSSL
111125
echo extension=php_openssl.dll >> %PHP_BUILD_DIR%\php.ini
112126

113127
rem remove ext dlls for which tests are not supported
114-
for %%i in (ldap oci8_12c pdo_firebird pdo_oci) do (
128+
for %%i in (ldap oci8_12c pdo_oci) do (
115129
del %PHP_BUILD_DIR%\php_%%i.dll
116130
)
117131

ext/pdo/tests/bug_73234.phpt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ pdo
66
<?php
77
$dir = getenv('REDIR_TEST_DIR');
88
if (false == $dir) die('skip no driver');
9+
if (str_starts_with(getenv('PDOTEST_DSN'), "firebird")) die('xfail firebird driver does not behave as expected');
910
require_once $dir . 'pdo_test.inc';
1011
PDOTest::skip();
1112
?>

ext/pdo/tests/gh8626.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ array(3) {
4141
[0]=>
4242
string(%d) "%s"
4343
[1]=>
44-
int(%d)
44+
int(%i)
4545
[2]=>
4646
string(%d) "%s%w%S"
4747
}

ext/pdo/tests/pdo_039.phpt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ pdo
66
<?php
77
$dir = getenv('REDIR_TEST_DIR');
88
if (false == $dir) die('skip no driver');
9+
if (str_starts_with(getenv('PDOTEST_DSN'), "firebird")) die('xfail firebird driver does not behave as expected');
910
require_once $dir . 'pdo_test.inc';
1011
PDOTest::skip();
1112
?>

0 commit comments

Comments
 (0)