On 02/05/2019 14:35, Kalle Sommer Nielsen wrote:
Hi Christoph

Den tor. 2. maj 2019 kl. 14.56 skrev Christoph M. Becker <cmbecke...@gmx.de>:
A problem is that the ext/pdo_firebird tests rely on ext/interbase to
create a test database[1], which would require everybody who intends to
run these tests to install PECL/interbase package now.  It would be
great if somebody would rewrite this, so interbase would no longer be a
dependency of the pdo_firebird tests.

[1] <https://github.com/php/php-src/blob/PHP-7.4/ext/pdo_firebird/tests
/testdb.inc>

Yeah that is one thing that is kind of unfortunate and a bad practice.
However since interbase was disabled for AppVeyor, these tests had no
chance to run in a while. Looking at the actual code in testdb.inc, it
seems like it creates the database for testing purposes, I would
suppose this is due to PDO_Firebird perhaps requiring a database to
continue its connection flow in PDO itself.

I'm not sure how we can go about this, maybe a .sql file for testers
who run the test suite for schemas and then see if we can integrate
some auto importer in our CI build scripts for this special case? (In
the case we cannot go around PDO). Either way the test files requires
a manual touch to configure credentials to run.

I'm personally fine with the simple solution, thoughts?

Firebird requires the database to exist before PDO can make a connection and there are a number of ways to handle it, but the simple solution is to use the example database that comes with Firebird. What does complicate things though is that distributions often bundle it separately, and will 'improve security' by not using the default user login. Hence the credentials problem becomes installation dependent. A default install using the official Firebird distributions should work with the test suite using the sample database rather than the temporary one.

--
Lester Caine - G8HFL
-----------------------------
Contact - https://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - https://lsces.co.uk
EnquirySolve - https://enquirysolve.com/
Model Engineers Digital Workshop - https://medw.co.uk
Rainbow Digital Media - https://rainbowdigitalmedia.co.uk

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to