diff options
author | Anatol Belski <ab@php.net> | 2018-01-04 16:10:37 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2018-01-04 16:10:37 +0100 |
commit | 205f527379246fa575742286156c5ea67a569804 (patch) | |
tree | 176e7d385d2d70203e73031829e559f693f54ce8 /ext/pdo_pgsql | |
parent | 8fe0ee690c6a82e3ba568e613280847d996c65b4 (diff) | |
parent | fc6a9908911697c48da9810e1fca965f61694fc2 (diff) | |
download | php-git-205f527379246fa575742286156c5ea67a569804.tar.gz |
Merge branch 'PHP-7.2'
* PHP-7.2:
Fix tests
Diffstat (limited to 'ext/pdo_pgsql')
-rw-r--r-- | ext/pdo_pgsql/tests/bug62479.phpt | 5 | ||||
-rw-r--r-- | ext/pdo_pgsql/tests/bug69362.phpt | 3 |
2 files changed, 5 insertions, 3 deletions
diff --git a/ext/pdo_pgsql/tests/bug62479.phpt b/ext/pdo_pgsql/tests/bug62479.phpt index 913321828e..efe4ece4e6 100644 --- a/ext/pdo_pgsql/tests/bug62479.phpt +++ b/ext/pdo_pgsql/tests/bug62479.phpt @@ -37,6 +37,7 @@ $db->exec("DROP USER $user"); ?> --FILE-- <?php +require dirname(__FILE__) . '/config.inc'; require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; $pdo = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); $pdo->setAttribute(PDO::ATTR_EMULATE_PREPARES, true); @@ -49,7 +50,7 @@ $testQuery = 'SELECT 1 as verification'; // Create temp user with space in password $sql = sprintf($template, 'my password'); $pdo->query($sql); -$testConn = new PDO($conf['ENV']['PDOTEST_DSN'], $user, "my password"); +$testConn = new PDO($config['ENV']['PDOTEST_DSN'], $user, "my password"); $result = $testConn->query($testQuery)->fetch(); $check = $result[0]; var_dump($check); @@ -61,7 +62,7 @@ $pdo->query($dropUser); $sql = sprintf($template, "my pass''word"); $pdo->query($sql); -$testConn = new PDO($conf['ENV']['PDOTEST_DSN'], $user, "my pass'word"); +$testConn = new PDO($config['ENV']['PDOTEST_DSN'], $user, "my pass'word"); $result = $testConn->query($testQuery)->fetch(); $check = $result[0]; var_dump($check); diff --git a/ext/pdo_pgsql/tests/bug69362.phpt b/ext/pdo_pgsql/tests/bug69362.phpt index 33212a8863..e986af8578 100644 --- a/ext/pdo_pgsql/tests/bug69362.phpt +++ b/ext/pdo_pgsql/tests/bug69362.phpt @@ -37,6 +37,7 @@ $db->exec("DROP USER $user"); ?> --FILE-- <?php +require dirname(__FILE__) . '/config.inc'; require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; $pdo = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); $pdo->setAttribute(PDO::ATTR_EMULATE_PREPARES, true); @@ -49,7 +50,7 @@ $testQuery = 'SELECT 1 as verification'; // Create temp user with leading single quote $sql = sprintf($template, "''mypassword"); $pdo->query($sql); -$testConn = new PDO($conf['ENV']['PDOTEST_DSN'], $user, "'mypassword"); +$testConn = new PDO($config['ENV']['PDOTEST_DSN'], $user, "'mypassword"); $result = $testConn->query($testQuery)->fetch(); $check = $result[0]; var_dump($check); |