mirror of
https://github.com/php/php-src.git
synced 2026-04-29 11:13:36 +02:00
d6a0b3af68
RFC: https://wiki.php.net/rfc/pdo_driver_specific_subclasses Closes GH-12804 Co-Authored-By: Danack <Danack@basereality.com>
18 lines
383 B
PHP
18 lines
383 B
PHP
--TEST--
|
|
Calling PDO::connect through the wrong classname
|
|
--EXTENSIONS--
|
|
pdo_pgsql
|
|
pdo_sqlite
|
|
--FILE--
|
|
<?php
|
|
|
|
try {
|
|
PdoPgSql::connect('sqlite::memory:');
|
|
} catch (PDOException $e) {
|
|
echo $e->getMessage() . "\n";
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
PdoPgsql::connect() cannot be called when connecting to the "sqlite" driver, either PdoSqlite::connect() or PDO::connect() must be called instead
|