diff options
author | Anatol Belski <ab@php.net> | 2018-01-04 16:09:51 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2018-01-04 16:09:51 +0100 |
commit | fc6a9908911697c48da9810e1fca965f61694fc2 (patch) | |
tree | 60862fd8ca5793e2c2b4c24fa2a1a28a5022b8aa /ext/pdo_pgsql | |
parent | fc528afd2bfb342de9809dad16d8494154c7c1ae (diff) | |
parent | 1448f0912f088c9da7270b94875225b6cc4993e6 (diff) | |
download | php-git-fc6a9908911697c48da9810e1fca965f61694fc2.tar.gz |
Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
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); |