diff options
Diffstat (limited to 'ext/pdo_mysql')
120 files changed, 446 insertions, 446 deletions
diff --git a/ext/pdo_mysql/tests/bug41125.phpt b/ext/pdo_mysql/tests/bug41125.phpt index 66ecbc7d4d..2212bb621d 100644 --- a/ext/pdo_mysql/tests/bug41125.phpt +++ b/ext/pdo_mysql/tests/bug41125.phpt @@ -2,17 +2,17 @@ Bug #41125 (PDO mysql + quote() + prepare() can result in seg fault) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $search = "o'"; $sql = "SELECT 1 FROM DUAL WHERE 'o''riley' LIKE " . $db->quote('%' . $search . '%'); diff --git a/ext/pdo_mysql/tests/bug44327.phpt b/ext/pdo_mysql/tests/bug44327.phpt index cb2fbda097..27a926295c 100644 --- a/ext/pdo_mysql/tests/bug44327.phpt +++ b/ext/pdo_mysql/tests/bug44327.phpt @@ -2,14 +2,14 @@ Bug #44327 (PDORow::queryString property & numeric offsets / Crash) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $stmt = $db->prepare("SELECT 1 AS \"one\""); diff --git a/ext/pdo_mysql/tests/bug46292.phpt b/ext/pdo_mysql/tests/bug46292.phpt index 8885384f1c..fd2ef759e5 100644 --- a/ext/pdo_mysql/tests/bug46292.phpt +++ b/ext/pdo_mysql/tests/bug46292.phpt @@ -2,14 +2,14 @@ Bug #46292 (PDO::setFetchMode() shouldn't requires the 2nd arg when using FETCH_CLASSTYPE) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $pdoDb = MySQLPDOTest::factory(); @@ -51,7 +51,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS testz'); ?> diff --git a/ext/pdo_mysql/tests/bug53551.phpt b/ext/pdo_mysql/tests/bug53551.phpt index 865dceaa1b..cb7e0fa2b6 100644 --- a/ext/pdo_mysql/tests/bug53551.phpt +++ b/ext/pdo_mysql/tests/bug53551.phpt @@ -2,8 +2,8 @@ Bug #44327 (PDORow::queryString property & numeric offsets / Crash) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> diff --git a/ext/pdo_mysql/tests/bug53782.phpt b/ext/pdo_mysql/tests/bug53782.phpt index 4f81cceef2..6620abc065 100644 --- a/ext/pdo_mysql/tests/bug53782.phpt +++ b/ext/pdo_mysql/tests/bug53782.phpt @@ -3,15 +3,15 @@ PDO MySQL Bug #53782 (foreach throws irrelevant exception) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$conn = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$conn = PDOTest::test_factory(__DIR__ . '/common.phpt'); $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); @@ -31,7 +31,7 @@ echo "DONE"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/bug54929.phpt b/ext/pdo_mysql/tests/bug54929.phpt index d7b4c7ad7f..6f2c2b0b80 100644 --- a/ext/pdo_mysql/tests/bug54929.phpt +++ b/ext/pdo_mysql/tests/bug54929.phpt @@ -2,17 +2,17 @@ Bug #54929 (Parse error with single quote in sql comment (pdo-mysql)) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); -$pdodb = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +$pdodb = PDOTest::test_factory(__DIR__ . '/common.phpt'); function testQuery($query) { diff --git a/ext/pdo_mysql/tests/bug63176.phpt b/ext/pdo_mysql/tests/bug63176.phpt index c5be644450..ed462c0c53 100644 --- a/ext/pdo_mysql/tests/bug63176.phpt +++ b/ext/pdo_mysql/tests/bug63176.phpt @@ -2,13 +2,13 @@ Bug #63176 (Segmentation fault when instantiate 2 persistent PDO to the same db server) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require(dirname(__FILE__). DIRECTORY_SEPARATOR . 'config.inc'); +require(__DIR__. DIRECTORY_SEPARATOR . 'config.inc'); class PDO2 extends PDO { protected $transLevel; } diff --git a/ext/pdo_mysql/tests/bug66141.phpt b/ext/pdo_mysql/tests/bug66141.phpt index bddf08e9f2..6d16a14a1c 100644 --- a/ext/pdo_mysql/tests/bug66141.phpt +++ b/ext/pdo_mysql/tests/bug66141.phpt @@ -2,8 +2,8 @@ Bug #66141 (mysqlnd quote function is wrong with NO_BACKSLASH_ESCAPES after failed query) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- diff --git a/ext/pdo_mysql/tests/bug68371.phpt b/ext/pdo_mysql/tests/bug68371.phpt index 77ddc3183e..f5046f0375 100644 --- a/ext/pdo_mysql/tests/bug68371.phpt +++ b/ext/pdo_mysql/tests/bug68371.phpt @@ -2,13 +2,13 @@ PDO MySQL Bug #38671 (PDO#getAttribute() cannot be called with platform-specific attribute names) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $pdo = MySQLPDOTest::factory(); $pdo->setAttribute (\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION); diff --git a/ext/pdo_mysql/tests/bug70272.phpt b/ext/pdo_mysql/tests/bug70272.phpt index cd9b9d7da2..eba1203868 100644 --- a/ext/pdo_mysql/tests/bug70272.phpt +++ b/ext/pdo_mysql/tests/bug70272.phpt @@ -2,8 +2,8 @@ Bug #70272 (Segfault in pdo_mysql) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --INI-- @@ -12,11 +12,11 @@ report_memleaks=off <?php $a = new Stdclass(); $a->a = &$a; -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dummy = new StdClass(); -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $dummy = NULL; $a->c = $db; diff --git a/ext/pdo_mysql/tests/bug70389.phpt b/ext/pdo_mysql/tests/bug70389.phpt index 2245459b94..09f439804e 100644 --- a/ext/pdo_mysql/tests/bug70389.phpt +++ b/ext/pdo_mysql/tests/bug70389.phpt @@ -2,13 +2,13 @@ Bug #70389 (PDO constructor changes unrelated variables) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require(dirname(__FILE__). DIRECTORY_SEPARATOR . 'config.inc'); +require(__DIR__. DIRECTORY_SEPARATOR . 'config.inc'); $flags = [ PDO::MYSQL_ATTR_FOUND_ROWS => true, PDO::MYSQL_ATTR_LOCAL_INFILE => true, diff --git a/ext/pdo_mysql/tests/bug70862.phpt b/ext/pdo_mysql/tests/bug70862.phpt index 527d9544de..d54d19f17b 100644 --- a/ext/pdo_mysql/tests/bug70862.phpt +++ b/ext/pdo_mysql/tests/bug70862.phpt @@ -2,13 +2,13 @@ MySQL Prepared Statements and BLOBs --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); @@ -37,7 +37,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/bug71569.phpt b/ext/pdo_mysql/tests/bug71569.phpt index 32c14b4622..15dfd82cd1 100644 --- a/ext/pdo_mysql/tests/bug71569.phpt +++ b/ext/pdo_mysql/tests/bug71569.phpt @@ -2,13 +2,13 @@ Bug #71569 (#70389 fix causes segmentation fault) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require(dirname(__FILE__). DIRECTORY_SEPARATOR . 'config.inc'); +require(__DIR__. DIRECTORY_SEPARATOR . 'config.inc'); try { new PDO(PDO_MYSQL_TEST_DSN, PDO_MYSQL_TEST_USER, PDO_MYSQL_TEST_PASS, [ diff --git a/ext/pdo_mysql/tests/bug75177.phpt b/ext/pdo_mysql/tests/bug75177.phpt index abdfd3954b..3a9127cb1e 100644 --- a/ext/pdo_mysql/tests/bug75177.phpt +++ b/ext/pdo_mysql/tests/bug75177.phpt @@ -2,13 +2,13 @@ PDO MySQL Bug #75177 Type 'bit' is fetched as unexpected string --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $pdo = MySQLPDOTest::factory(); $tbl = "tbl_bug75177"; diff --git a/ext/pdo_mysql/tests/bug77289.phpt b/ext/pdo_mysql/tests/bug77289.phpt index db67524260..e8ea91262e 100644 --- a/ext/pdo_mysql/tests/bug77289.phpt +++ b/ext/pdo_mysql/tests/bug77289.phpt @@ -2,13 +2,13 @@ Bug #77289: PDO MySQL segfaults with persistent connection --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $user = PDO_MYSQL_TEST_USER; diff --git a/ext/pdo_mysql/tests/bug_33689.phpt b/ext/pdo_mysql/tests/bug_33689.phpt index bd193fa9ac..0755112f5f 100644 --- a/ext/pdo_mysql/tests/bug_33689.phpt +++ b/ext/pdo_mysql/tests/bug_33689.phpt @@ -3,15 +3,15 @@ PDO MySQL Bug #33689 (query() execute() and fetch() return false on valid select --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $db->exec('CREATE TABLE test (bar INT NOT NULL)'); $db->exec('INSERT INTO test VALUES(1)'); @@ -36,7 +36,7 @@ print_r($tmp); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/bug_37445.phpt b/ext/pdo_mysql/tests/bug_37445.phpt index 6a51233cc4..d43bedd619 100644 --- a/ext/pdo_mysql/tests/bug_37445.phpt +++ b/ext/pdo_mysql/tests/bug_37445.phpt @@ -3,14 +3,14 @@ PDO MySQL Bug #37445 (Premature stmt object destruction) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $db->setAttribute(PDO :: ATTR_EMULATE_PREPARES, true); $stmt = $db->prepare("SELECT 1"); diff --git a/ext/pdo_mysql/tests/bug_39483.phpt b/ext/pdo_mysql/tests/bug_39483.phpt Binary files differindex 559cad65ba..e0f1fd2ea3 100644 --- a/ext/pdo_mysql/tests/bug_39483.phpt +++ b/ext/pdo_mysql/tests/bug_39483.phpt diff --git a/ext/pdo_mysql/tests/bug_39858.phpt b/ext/pdo_mysql/tests/bug_39858.phpt index ec4c9586cc..0d850ede16 100644 --- a/ext/pdo_mysql/tests/bug_39858.phpt +++ b/ext/pdo_mysql/tests/bug_39858.phpt @@ -3,8 +3,8 @@ Bug #39858 (Lost connection to MySQL server during query by a repeated call stor --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -22,7 +22,7 @@ if ($version < 50000) nextRowset() problem with stored proc & emulation mode & mysqlnd --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true); @@ -66,7 +66,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec("DROP PROCEDURE IF EXISTS p"); ?> diff --git a/ext/pdo_mysql/tests/bug_41125.phpt b/ext/pdo_mysql/tests/bug_41125.phpt index a1d8dd1ae4..6d9041889e 100644 --- a/ext/pdo_mysql/tests/bug_41125.phpt +++ b/ext/pdo_mysql/tests/bug_41125.phpt @@ -2,8 +2,8 @@ Bug #41125 (PDO mysql + quote() + prepare() can result in segfault) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -20,7 +20,7 @@ if ($version < 40100) ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->exec("DROP TABLE IF EXISTS test"); @@ -40,7 +40,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec("DROP TABLE IF EXISTS test"); ?> diff --git a/ext/pdo_mysql/tests/bug_41698.phpt b/ext/pdo_mysql/tests/bug_41698.phpt index 637a0910b1..5b60da9daa 100644 --- a/ext/pdo_mysql/tests/bug_41698.phpt +++ b/ext/pdo_mysql/tests/bug_41698.phpt @@ -3,15 +3,15 @@ PDO MySQL Bug #41698 (float parameters truncated to integer in prepared statemen --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); setlocale(LC_ALL, "de","de_DE","de_DE.ISO8859-1","de_DE.ISO_8859-1","de_DE.UTF-8"); diff --git a/ext/pdo_mysql/tests/bug_41997.phpt b/ext/pdo_mysql/tests/bug_41997.phpt index 3a90244365..9d06a2f14b 100644 --- a/ext/pdo_mysql/tests/bug_41997.phpt +++ b/ext/pdo_mysql/tests/bug_41997.phpt @@ -4,8 +4,8 @@ PDO MySQL Bug #41997 (stored procedure call returning single rowset blocks futur nextRowset() problem with stored proc & emulation mode & mysqlnd --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -21,7 +21,7 @@ if ($version < 50000) ?> --FILE-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP PROCEDURE IF EXISTS p'); diff --git a/ext/pdo_mysql/tests/bug_42499.phpt b/ext/pdo_mysql/tests/bug_42499.phpt index e218e0c14e..a691d275d2 100644 --- a/ext/pdo_mysql/tests/bug_42499.phpt +++ b/ext/pdo_mysql/tests/bug_42499.phpt @@ -3,8 +3,8 @@ Bug #42499 (Multi-statement execution via PDO::exec() makes connection unusable) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); @@ -21,7 +21,7 @@ if ($version < 41000) $matches[0], $matches[1], $matches[2], $version)); --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function bug_42499($db) { diff --git a/ext/pdo_mysql/tests/bug_43371.phpt b/ext/pdo_mysql/tests/bug_43371.phpt index 88c3a9bc6f..80c2149f61 100644 --- a/ext/pdo_mysql/tests/bug_43371.phpt +++ b/ext/pdo_mysql/tests/bug_43371.phpt @@ -2,13 +2,13 @@ Bug #43371 (Memory errors in PDO constructor) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $db = new PDO($dsn, PDO_MYSQL_TEST_USER, PDO_MYSQL_TEST_PASS, array(PDO::ATTR_PERSISTENT => true)); diff --git a/ext/pdo_mysql/tests/bug_44454.phpt b/ext/pdo_mysql/tests/bug_44454.phpt index eb93d97952..d21cf3a4e2 100644 --- a/ext/pdo_mysql/tests/bug_44454.phpt +++ b/ext/pdo_mysql/tests/bug_44454.phpt @@ -3,15 +3,15 @@ Bug #44454 (Unexpected exception thrown in foreach() statement) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); function bug_44454($db) { @@ -69,7 +69,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/bug_44707.phpt b/ext/pdo_mysql/tests/bug_44707.phpt index d5d4539fcc..025b92e1fc 100644 --- a/ext/pdo_mysql/tests/bug_44707.phpt +++ b/ext/pdo_mysql/tests/bug_44707.phpt @@ -3,8 +3,8 @@ Bug #44707 (The MySQL PDO driver resets variable content after bindParam on tiny --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); @@ -22,9 +22,9 @@ if ($version < 41000) ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); function bug_44707($db) { diff --git a/ext/pdo_mysql/tests/bug_45120.phpt b/ext/pdo_mysql/tests/bug_45120.phpt index db5da823f7..bc2ea76629 100644 --- a/ext/pdo_mysql/tests/bug_45120.phpt +++ b/ext/pdo_mysql/tests/bug_45120.phpt @@ -3,15 +3,15 @@ Bug #45120 (PDOStatement->execute() returns true then false for same statement) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); function bug_45120($db) { diff --git a/ext/pdo_mysql/tests/bug_50323.phpt b/ext/pdo_mysql/tests/bug_50323.phpt index 30f856efc8..3997ccf398 100644 --- a/ext/pdo_mysql/tests/bug_50323.phpt +++ b/ext/pdo_mysql/tests/bug_50323.phpt @@ -3,14 +3,14 @@ Bug #50323 (No ability to connect to database named 't;', no chance to escape se --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); function changeDSN($original, $new_options) { $old_options = array(); @@ -51,8 +51,8 @@ echo 'done!'; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); @$db->exec('DROP DATABASE IF EXISTS `crazy;dbname`'); ?> diff --git a/ext/pdo_mysql/tests/bug_51670.phpt b/ext/pdo_mysql/tests/bug_51670.phpt index b2a1219991..22b3e63470 100644 --- a/ext/pdo_mysql/tests/bug_51670.phpt +++ b/ext/pdo_mysql/tests/bug_51670.phpt @@ -3,14 +3,14 @@ Bug #51670 (getColumnMeta causes segfault when re-executing query after calling --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $query = $db->prepare('SELECT 1 AS num'); $query->execute(); if(!is_array($query->getColumnMeta(0))) die('FAIL!'); diff --git a/ext/pdo_mysql/tests/bug_61207.phpt b/ext/pdo_mysql/tests/bug_61207.phpt index 411b39a70b..346c1687e7 100644 --- a/ext/pdo_mysql/tests/bug_61207.phpt +++ b/ext/pdo_mysql/tests/bug_61207.phpt @@ -2,14 +2,14 @@ PDO MySQL Bug #61207 (PDO::nextRowset() after a multi-statement query doesn't always work) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->query('DROP TABLE IF EXISTS test'); @@ -84,7 +84,7 @@ $db->query("DROP TABLE test"); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/bug_61411.phpt b/ext/pdo_mysql/tests/bug_61411.phpt index d840f222f1..7c7ae98db1 100644 --- a/ext/pdo_mysql/tests/bug_61411.phpt +++ b/ext/pdo_mysql/tests/bug_61411.phpt @@ -3,8 +3,8 @@ Bug #61411 (PDO Segfaults with PERSISTENT == TRUE && EMULATE_PREPARES == FALSE) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -20,7 +20,7 @@ if ($version < 40106) ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $attr = getenv('PDOTEST_ATTR'); if (!$attr) { diff --git a/ext/pdo_mysql/tests/bug_61755.phpt b/ext/pdo_mysql/tests/bug_61755.phpt index a6f55f5938..ccd8a964dd 100644 --- a/ext/pdo_mysql/tests/bug_61755.phpt +++ b/ext/pdo_mysql/tests/bug_61755.phpt @@ -3,14 +3,14 @@ Bug #61755 (A parsing bug in the prepared statements can lead to access violatio --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); diff --git a/ext/pdo_mysql/tests/bug_74376.phpt b/ext/pdo_mysql/tests/bug_74376.phpt index 1d2acfdc69..5abc546d15 100644 --- a/ext/pdo_mysql/tests/bug_74376.phpt +++ b/ext/pdo_mysql/tests/bug_74376.phpt @@ -3,13 +3,13 @@ Bug #74376 (Invalid free of persistent results on error/connection loss) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $attr = getenv('PDOTEST_ATTR'); $attr = $attr ? unserialize($attr) : []; diff --git a/ext/pdo_mysql/tests/bug_pecl_12925.phpt b/ext/pdo_mysql/tests/bug_pecl_12925.phpt index a893fb81b7..361ef719d0 100644 --- a/ext/pdo_mysql/tests/bug_pecl_12925.phpt +++ b/ext/pdo_mysql/tests/bug_pecl_12925.phpt @@ -3,14 +3,14 @@ PDO MySQL PECL bug #1295 (http://pecl.php.net/bugs/bug.php?id=12925) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function bug_pecl_1295($db) { diff --git a/ext/pdo_mysql/tests/bug_pecl_7976.phpt b/ext/pdo_mysql/tests/bug_pecl_7976.phpt index 8a1362599b..ee5d5e95b1 100644 --- a/ext/pdo_mysql/tests/bug_pecl_7976.phpt +++ b/ext/pdo_mysql/tests/bug_pecl_7976.phpt @@ -3,8 +3,8 @@ PECL Bug #7976 (Calling stored procedure several times) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -20,7 +20,7 @@ if ($version < 50000) ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function bug_pecl_7976($db) { @@ -52,7 +52,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP PROCEDURE IF EXISTS p'); ?> diff --git a/ext/pdo_mysql/tests/last_insert_id.phpt b/ext/pdo_mysql/tests/last_insert_id.phpt index c819efe1e6..4b32d1cda2 100644 --- a/ext/pdo_mysql/tests/last_insert_id.phpt +++ b/ext/pdo_mysql/tests/last_insert_id.phpt @@ -3,14 +3,14 @@ PDO MySQL auto_increment / last insert id --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); print_r($db->query("CREATE TABLE test (id int auto_increment primary key, num int)")); diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt index 219678c671..b849f274be 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt @@ -2,13 +2,13 @@ MySQL PDO->__construct() - Generic + DSN --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function tryandcatch($offset, $code) { diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_ini.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_ini.phpt index e24f66c09d..a03ad7f324 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_ini.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_ini.phpt @@ -2,8 +2,8 @@ MySQL PDO->__construct() - URI --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); /* TODO - fix this limitation */ if (getenv('PDO_MYSQL_TEST_DSN') !== "mysql:dbname=phptest;unix_socket=/tmp/mysql.sock") @@ -13,7 +13,7 @@ if (getenv('PDO_MYSQL_TEST_DSN') !== "mysql:dbname=phptest;unix_socket=/tmp/mysq pdo.dsn.mysql="mysql:dbname=phptest;socket=/tmp/mysql.sock" --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $found = false; $values = ini_get_all(); diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt index 08cd8eb942..9482a13bfa 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt @@ -2,13 +2,13 @@ MySQL PDO->__construct(), options --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function set_option_and_check($offset, $option, $value, $option_desc) { diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_options_libmysql.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_options_libmysql.phpt index 133d42215d..d01ef0a69a 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_options_libmysql.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_options_libmysql.phpt @@ -2,15 +2,15 @@ MySQL PDO->__construct(), libmysql only options --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); if (MySQLPDOTest::isPDOMySQLnd()) die("skip libmysql only options") ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function set_option_and_check($offset, $option, $value, $option_desc, $ignore_diff = false) { diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_uri-win32.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_uri-win32.phpt index b4609b1629..73f2ddf4a1 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_uri-win32.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_uri-win32.phpt @@ -5,13 +5,13 @@ MySQL PDO->__construct() - URI if (substr(PHP_OS, 0, 3) != 'WIN') { die('skip only for Windows'); } -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); try { diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_uri.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_uri.phpt index 0b1cf3fe65..6cd7107001 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_uri.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_uri.phpt @@ -5,13 +5,13 @@ MySQL PDO->__construct() - URI if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip not for Windows'); } -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); try { diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_autocommit.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_autocommit.phpt index 95e6ff9875..361750260b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_autocommit.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_autocommit.phpt @@ -2,14 +2,14 @@ PDO::ATTR_AUTOCOMMIT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); // autocommit should be on by default @@ -91,7 +91,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_case.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_case.phpt index 6c39467b12..a011c864c5 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_case.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_case.phpt @@ -2,14 +2,14 @@ PDO::ATTR_CASE --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -86,7 +86,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_client_version.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_client_version.phpt index 19831da979..ce50df80eb 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_client_version.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_client_version.phpt @@ -2,14 +2,14 @@ PDO::ATTR_CLIENT_VERSION --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); assert(('' == $db->errorCode()) || ('00000' == $db->errorCode())); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_connection_status.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_connection_status.phpt index 9fd9bf9b26..8abb16a1c7 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_connection_status.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_connection_status.phpt @@ -2,14 +2,14 @@ PDO::ATTR_CONNECTION_STATUS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $status = $db->getAttribute(PDO::ATTR_CONNECTION_STATUS); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_driver_name.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_driver_name.phpt index 708e3a2efc..65ab531ffd 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_driver_name.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_driver_name.phpt @@ -2,14 +2,14 @@ PDO::ATTR_DRIVER_NAME --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); assert(('' == $db->errorCode()) || ('00000' == $db->errorCode())); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_errmode.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_errmode.phpt index 4db50f074f..f0dc29b8d4 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_errmode.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_errmode.phpt @@ -2,8 +2,8 @@ PDO::ATTR_ERRMODE --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> @@ -11,7 +11,7 @@ $db = MySQLPDOTest::factory(); error_reporting=E_ALL --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $valid = array(PDO::ERRMODE_SILENT, PDO::ERRMODE_WARNING, PDO::ERRMODE_EXCEPTION); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_fetch_table_names.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_fetch_table_names.phpt index b85ba236f8..a19e680de1 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_fetch_table_names.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_fetch_table_names.phpt @@ -2,13 +2,13 @@ PDO::ATTR_FETCH_TABLE_NAMES --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_init_command.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_init_command.phpt index 4ef6e52976..cd3b40d6d1 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_init_command.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_init_command.phpt @@ -2,8 +2,8 @@ PDO::MYSQL_ATTR_INIT_COMMAND --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> @@ -11,7 +11,7 @@ $db = MySQLPDOTest::factory(); error_reporting=E_ALL --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $user = PDO_MYSQL_TEST_USER; diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_max_buffer_size.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_max_buffer_size.phpt index c9aa5aaac4..c988b2b3cb 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_max_buffer_size.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_max_buffer_size.phpt @@ -2,15 +2,15 @@ MySQL PDO->__construct(), PDO::MYSQL_ATTR_MAX_BUFFER_SIZE --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); if (MySQLPDOTest::isPDOMySQLnd()) die("skip PDO::MYSQL_ATTR_MAX_BUFFER_SIZE not supported with mysqlnd"); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function try_buffer_size($offset, $buffer_size) { @@ -65,7 +65,7 @@ if (MySQLPDOTest::isPDOMySQLnd()) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_multi_statements.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_multi_statements.phpt index b10e82afcb..92bab1d30d 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_multi_statements.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_multi_statements.phpt @@ -2,8 +2,8 @@ PDO::MYSQL_ATTR_MULTI_STATEMENTS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> @@ -11,7 +11,7 @@ $db = MySQLPDOTest::factory(); error_reporting=E_ALL --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $user = PDO_MYSQL_TEST_USER; diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_oracle_nulls.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_oracle_nulls.phpt index 3a937c7dee..44503c1053 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_oracle_nulls.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_oracle_nulls.phpt @@ -2,13 +2,13 @@ PDO::ATTR_ORACLE_NULLS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_prefetch.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_prefetch.phpt index 41dcf06f40..f1ca4be1de 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_prefetch.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_prefetch.phpt @@ -2,14 +2,14 @@ PDO::ATTR_PREFETCH --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); var_dump($db->getAttribute(PDO::ATTR_PREFETCH)); var_dump($db->setAttribute(PDO::ATTR_PREFETCH, true)); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_server_info.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_server_info.phpt index 9c3087384b..206b236311 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_server_info.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_server_info.phpt @@ -2,14 +2,14 @@ PDO::ATTR_SERVER_INFO --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); assert(('' == $db->errorCode()) || ('00000' == $db->errorCode())); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_server_version.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_server_version.phpt index 0a50c8d46a..a635c3771a 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_server_version.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_server_version.phpt @@ -2,14 +2,14 @@ PDO::ATTR_SERVER_VERSION --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); assert(('' == $db->errorCode()) || ('00000' == $db->errorCode())); diff --git a/ext/pdo_mysql/tests/pdo_mysql_attr_statement_class.phpt b/ext/pdo_mysql/tests/pdo_mysql_attr_statement_class.phpt index d733a2b544..237f03af38 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_attr_statement_class.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_attr_statement_class.phpt @@ -2,14 +2,14 @@ PDO::ATTR_STATEMENT_CLASS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); diff --git a/ext/pdo_mysql/tests/pdo_mysql_begintransaction.phpt b/ext/pdo_mysql/tests/pdo_mysql_begintransaction.phpt index 1cd24f0dbf..f2653f4b6b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_begintransaction.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_begintransaction.phpt @@ -2,8 +2,8 @@ PDO->beginTransaction() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) @@ -11,7 +11,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -183,7 +183,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_bit.phpt b/ext/pdo_mysql/tests/pdo_mysql_bit.phpt index f27e3d8c78..caa81e96ac 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_bit.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_bit.phpt @@ -2,8 +2,8 @@ MySQL PDO->exec(), BIT columns - remove after fix! --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); if (MySQLPDOTest::isPDOMySQLnd()) die("skip Known bug - mysqlnd handles BIT incorrectly!"); @@ -11,7 +11,7 @@ if (MySQLPDOTest::isPDOMySQLnd()) --FILE-- <?php /* TODO: remove this test after fix and enable the BIT test in pdo_mysql_types.phpt again */ - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function test_type(&$db, $offset, $sql_type, $value, $ret_value = NULL, $pattern = NULL) { @@ -49,7 +49,7 @@ if (MySQLPDOTest::isPDOMySQLnd()) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt index 090f97d043..05f3151e8b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt @@ -2,16 +2,16 @@ PDO MySQL specific class constants --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); if (!extension_loaded('mysqli') && !extension_loaded('mysqlnd')) { /* Need connection to detect library version */ - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); } ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $expected = array( 'MYSQL_ATTR_USE_BUFFERED_QUERY' => true, diff --git a/ext/pdo_mysql/tests/pdo_mysql_commit.phpt b/ext/pdo_mysql/tests/pdo_mysql_commit.phpt index 2219ae8ed4..6141ff611b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_commit.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_commit.phpt @@ -2,8 +2,8 @@ MySQL PDO->commit() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) @@ -11,7 +11,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -81,7 +81,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) print "done!"; --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test_commit'); MySQLPDOTest::dropTestTable($db); diff --git a/ext/pdo_mysql/tests/pdo_mysql_connect_charset.phpt b/ext/pdo_mysql/tests/pdo_mysql_connect_charset.phpt index f7dede52ef..84ce556d32 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_connect_charset.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_connect_charset.phpt @@ -2,13 +2,13 @@ PDO_MYSQL: Defining a connection charset in the DSN --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); /* Connect to mysql to determine the current charset so we can diffinate it */ $link = MySQLPDOTest::factory(); diff --git a/ext/pdo_mysql/tests/pdo_mysql_errorcode.phpt b/ext/pdo_mysql/tests/pdo_mysql_errorcode.phpt index a974f29df9..5bf6c10448 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_errorcode.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_errorcode.phpt @@ -2,14 +2,14 @@ MySQL PDO->errorCode() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -79,7 +79,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_errorinfo.phpt b/ext/pdo_mysql/tests/pdo_mysql_errorinfo.phpt index dca3b2305b..487f8ab97a 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_errorinfo.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_errorinfo.phpt @@ -2,14 +2,14 @@ MySQL PDO->errorInfo() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -98,7 +98,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_exec.phpt b/ext/pdo_mysql/tests/pdo_mysql_exec.phpt index acd90904f7..cdca014108 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_exec.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_exec.phpt @@ -2,8 +2,8 @@ MySQL PDO->exec(), affected rows --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- @@ -29,7 +29,7 @@ MySQLPDOTest::skip(); return true; } - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -174,7 +174,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); @$db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_exec_ddl.phpt b/ext/pdo_mysql/tests/pdo_mysql_exec_ddl.phpt index 8afd07bef0..0b2428cc1c 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_exec_ddl.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_exec_ddl.phpt @@ -2,8 +2,8 @@ MySQL PDO->exec(), affected rows --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- @@ -33,7 +33,7 @@ MySQLPDOTest::skip(); return true; } - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -79,7 +79,7 @@ MySQLPDOTest::skip(); print "done!"; --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); MySQLPDOTest::dropTestTable($db); // clean up diff --git a/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt b/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt index e1ca9e1e16..50b35618b3 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt @@ -2,8 +2,8 @@ MySQL PDO->exec(), affected rows --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); // Run test only locally - not against remote hosts @@ -58,7 +58,7 @@ if (($row = $stmt->fetch(PDO::FETCH_ASSOC)) && ($row['value'] != '')) { return true; } - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); putenv('PDOTEST_ATTR='.serialize([PDO::MYSQL_ATTR_LOCAL_INFILE=>true])); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -112,7 +112,7 @@ if (($row = $stmt->fetch(PDO::FETCH_ASSOC)) && ($row['value'] != '')) { ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_exec_select.phpt b/ext/pdo_mysql/tests/pdo_mysql_exec_select.phpt index f8900a0ef3..901a4ad9a8 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_exec_select.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_exec_select.phpt @@ -2,8 +2,8 @@ MySQL PDO->exec(), SELECT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- @@ -29,7 +29,7 @@ MySQLPDOTest::skip(); return true; } - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -55,7 +55,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); @$db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_fetch_both.phpt b/ext/pdo_mysql/tests/pdo_mysql_fetch_both.phpt index 9303a3119d..0e53d40deb 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_fetch_both.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_fetch_both.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->fetch() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function fetch($offset, &$db, $query, $expect = null) { diff --git a/ext/pdo_mysql/tests/pdo_mysql_get_attribute.phpt b/ext/pdo_mysql/tests/pdo_mysql_get_attribute.phpt index 8ab2c98b4c..2eb34cd076 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_get_attribute.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_get_attribute.phpt @@ -2,8 +2,8 @@ MySQL PDO->getAttribute() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) @@ -11,7 +11,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -98,7 +98,7 @@ PDO::ATTR_SERVER_INFO ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_interface.phpt b/ext/pdo_mysql/tests/pdo_mysql_interface.phpt index 306778614b..cc949b265d 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_interface.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_interface.phpt @@ -2,8 +2,8 @@ MySQL PDO class interface --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) @@ -11,7 +11,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $expected = array( diff --git a/ext/pdo_mysql/tests/pdo_mysql_last_insert_id.phpt b/ext/pdo_mysql/tests/pdo_mysql_last_insert_id.phpt index 0ce9e1e539..d9dec0bcd3 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_last_insert_id.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_last_insert_id.phpt @@ -2,14 +2,14 @@ MySQL PDO->lastInsertId() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -112,7 +112,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_local_infile_default_off.phpt b/ext/pdo_mysql/tests/pdo_mysql_local_infile_default_off.phpt index a47bbbed31..1f1e6d9668 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_local_infile_default_off.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_local_infile_default_off.phpt @@ -2,16 +2,16 @@ ensure default for local infile is off --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); if (!MYSQLPDOTest::isPDOMySQLnd()) die("skip mysqlnd only test"); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'config.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'config.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $user = PDO_MYSQL_TEST_USER; diff --git a/ext/pdo_mysql/tests/pdo_mysql_local_infile_set_on.phpt b/ext/pdo_mysql/tests/pdo_mysql_local_infile_set_on.phpt index 3b942a4d2e..13df9024a2 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_local_infile_set_on.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_local_infile_set_on.phpt @@ -2,16 +2,16 @@ enable local infile --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); if (!MYSQLPDOTest::isPDOMySQLnd()) die("skip mysqlnd only test"); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'config.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'config.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $dsn = MySQLPDOTest::getDSN(); $user = PDO_MYSQL_TEST_USER; diff --git a/ext/pdo_mysql/tests/pdo_mysql_multi_stmt_nextrowset.phpt b/ext/pdo_mysql/tests/pdo_mysql_multi_stmt_nextrowset.phpt index 6398a83928..199a758a82 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_multi_stmt_nextrowset.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_multi_stmt_nextrowset.phpt @@ -2,8 +2,8 @@ MySQL PDOStatement->nextRowSet() with PDO::MYSQL_ATTR_MULTI_STATEMENTS either true or false --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); $row = $db->query('SELECT VERSION() as _version')->fetch(PDO::FETCH_ASSOC); @@ -21,7 +21,7 @@ if (!MySQLPDOTest::isPDOMySQLnd()) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true); @@ -83,7 +83,7 @@ if (!MySQLPDOTest::isPDOMySQLnd()) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_param_str_natl.phpt b/ext/pdo_mysql/tests/pdo_mysql_param_str_natl.phpt index 56b94483f3..01964c0cd9 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_param_str_natl.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_param_str_natl.phpt @@ -3,15 +3,15 @@ PDO MySQL national character set parameters don't affect true prepared statement --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); $db->setAttribute(PDO::ATTR_EMULATE_PREPARES, 0); @@ -29,7 +29,7 @@ foreach ($db->query('SELECT * from test') as $row) { ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt b/ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt index 880f10b875..3656e71a0c 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_pconnect.phpt @@ -2,13 +2,13 @@ MySQL PDO->__construct(), PDO::ATTR_PERSISTENT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); try { diff --git a/ext/pdo_mysql/tests/pdo_mysql_phpinfo.phpt b/ext/pdo_mysql/tests/pdo_mysql_phpinfo.phpt index 74b4a73584..a230b3c19f 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_phpinfo.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_phpinfo.phpt @@ -2,14 +2,14 @@ MySQL PDO phpinfo() output --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); ob_start(); diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated.phpt index 437ea7a458..8db812ee19 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), emulated PS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function prepex($offset, &$db, $query, $input_params = null, $error_info = null) { @@ -320,7 +320,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_anonymous.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_anonymous.phpt index 3f63ffcb01..e8b5cb39ae 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_anonymous.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_anonymous.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), emulated PS, anonymous placeholder --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -60,7 +60,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_placeholder_everywhere.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_placeholder_everywhere.phpt index 3a77d5eee1..5ad3c85641 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_placeholder_everywhere.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_emulated_placeholder_everywhere.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), emulated PS, anonymous placeholder --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); // TODO: This test is MySQL version specific - for whatever reason ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -56,7 +56,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_load_data.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_load_data.phpt index 958068f035..0e7dc4b3ab 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_load_data.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_load_data.phpt @@ -2,8 +2,8 @@ MySQL PDO->prepare() and 1295 (ER_UNSUPPORTED_PS) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); // Run test only locally - not against remote hosts @@ -58,7 +58,7 @@ if (($row = $stmt->fetch(PDO::FETCH_ASSOC)) && ($row['value'] != '')) { return true; } - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); // Run with native PS. // The test is about checking the fallback to emulation @@ -116,7 +116,7 @@ if (($row = $stmt->fetch(PDO::FETCH_ASSOC)) && ($row['value'] != '')) { ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_match_against.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_match_against.phpt index 12cf051647..f77c420d67 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_match_against.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_match_against.phpt @@ -2,13 +2,13 @@ Bug #41876 (bindParam() and bindValue() do not work with MySQL MATCH () AGAINST ()) --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -40,7 +40,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native.phpt index 13b9034788..c88b90663b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function prepex($offset, &$db, $query, $input_params = null, $error_info = null, $suppress_warning = false) { @@ -337,7 +337,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_clear_error.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_clear_error.phpt index 000e44b731..48bd33fda5 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_clear_error.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_clear_error.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS, clear line after error --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -70,7 +70,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_column.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_column.phpt index 8a942d0d32..1ee1c3a43b 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_column.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_column.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS, named placeholder --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -30,7 +30,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_dup_named_placeholder.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_dup_named_placeholder.phpt index e382dff375..c9465b62a2 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_dup_named_placeholder.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_dup_named_placeholder.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS, named placeholder II --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -96,7 +96,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_mixed_style.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_mixed_style.phpt index d56f7c6549..e706b92616 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_mixed_style.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_mixed_style.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS, mixed, wired style --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -28,7 +28,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_named_placeholder.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_named_placeholder.phpt index 896d9cd2a3..12acdcc0b1 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_named_placeholder.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_named_placeholder.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(), native PS, named placeholder --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -68,7 +68,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_placeholder_everywhere.phpt b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_placeholder_everywhere.phpt index 442e710e74..8df6961f93 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_prepare_native_placeholder_everywhere.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_prepare_native_placeholder_everywhere.phpt @@ -2,14 +2,14 @@ MySQL PDO->prepare(),native PS, anonymous placeholder --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { $db->setAttribute(PDO::MYSQL_ATTR_DIRECT_QUERY, 1); @@ -61,7 +61,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_quote.phpt b/ext/pdo_mysql/tests/pdo_mysql_quote.phpt index 3d094a4136..efb38ba576 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_quote.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_quote.phpt @@ -2,13 +2,13 @@ MySQL ensure quote function returns expected results --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); var_dump($db->quote('foo', PDO::PARAM_STR)); diff --git a/ext/pdo_mysql/tests/pdo_mysql_rollback.phpt b/ext/pdo_mysql/tests/pdo_mysql_rollback.phpt index 108975bcf8..30f1d56f88 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_rollback.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_rollback.phpt @@ -2,8 +2,8 @@ PDO::rollBack() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) @@ -11,7 +11,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db, MySQLPDOTest::detect_transactional_mysql_engine($db)); @@ -83,7 +83,7 @@ if (false == MySQLPDOTest::detect_transactional_mysql_engine($db)) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); $db->exec('DROP TABLE IF EXISTS test2'); diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindcolumn.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindcolumn.phpt index 1dd3ca0fa6..bf56cbc835 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindcolumn.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindcolumn.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->bindColumn() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -103,7 +103,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam.phpt index 4c3716de4b..422c519355 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->bindParam() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, false); @@ -118,7 +118,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam_types.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam_types.phpt index c23ef4b2fd..c6860fa539 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam_types.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindparam_types.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->bindParam() - SQL column types --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -166,7 +166,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindvalue.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindvalue.phpt index 42f01d5332..173105a48e 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_bindvalue.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_bindvalue.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->bindValue() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -297,7 +297,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_blobfromsteam.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_blobfromsteam.phpt index 2dedf35958..bea8773a23 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_blobfromsteam.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_blobfromsteam.phpt @@ -2,8 +2,8 @@ MySQL PDOStatement - inserting BLOB from stream --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $tmp = MySQLPDOTest::getTempDir(); @@ -28,7 +28,7 @@ unlink($file); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function blob_from_stream($offset, $db, $file, $blob) { @@ -137,7 +137,7 @@ unlink($file); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); @unlink(MySQLPDOTest::getTempDir() . DIRECTORY_SEPARATOR . 'pdoblob.tst'); diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_blobs.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_blobs.phpt index bec8b70caf..a247de534e 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_blobs.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_blobs.phpt @@ -2,13 +2,13 @@ MySQL Prepared Statements and BLOBs --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $blobs = array( @@ -90,7 +90,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor.phpt index 455b17d1ef..d0da7a8e16 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor.phpt @@ -2,15 +2,15 @@ MySQL PDOStatement->closeCursor() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php /* TODO the results look wrong, why do we get 2014 with buffered AND unbuffered queries */ - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function pdo_mysql_stmt_closecursor($db) { @@ -146,7 +146,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor_empty.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor_empty.phpt index 6b4e4d225f..77f663584a 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor_empty.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_closecursor_empty.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->closeCursor() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); @@ -63,7 +63,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_columncount.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_columncount.phpt index 69e0d35e17..a701469ed1 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_columncount.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_columncount.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->columnCount() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -56,7 +56,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_errorcode.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_errorcode.phpt index b4c75ebee1..f77ba60f75 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_errorcode.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_errorcode.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->errorCode(); --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS ihopeitdoesnotexist'); diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_errorinfo.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_errorinfo.phpt index 9254568db0..e9dbeab3a6 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_errorinfo.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_errorinfo.phpt @@ -2,14 +2,14 @@ MySQL PDOStatement->errorInfo(); --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -61,7 +61,7 @@ $db = MySQLPDOTest::factory(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_non_select.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_non_select.phpt index 255cd383a6..46ab4f911c 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_non_select.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_non_select.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->execute()/fetch(), Non-SELECT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -184,7 +184,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt index f23f9572c1..37dda2c0f5 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->fetch(), PDO::FETCH_SERIALIZE --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -115,7 +115,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt index 890c7b73cb..bfc907dbcb 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->fetch(), PDO::FETCH_SERIALIZE --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetchobject.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetchobject.phpt index e35f95a86f..ae14c056f3 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_fetchobject.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_fetchobject.phpt @@ -2,8 +2,8 @@ MySQL PDO: PDOStatement->fetchObject() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -19,7 +19,7 @@ if (!$ok) ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -77,7 +77,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_getcolumnmeta.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_getcolumnmeta.phpt index 07ad3d9d33..5ac683ea48 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_getcolumnmeta.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_getcolumnmeta.phpt @@ -2,8 +2,8 @@ MySQL: PDOStatement->getColumnMeta() --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); // Too many differences among MySQL version - run only with a recent one $db = MySQLPDOTest::factory(); @@ -15,7 +15,7 @@ if ($version < 51) ?> --FILE-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true); MySQLPDOTest::createTestTable($db); diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_multiquery.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_multiquery.phpt index d2a2316272..9e36714d54 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_multiquery.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_multiquery.phpt @@ -2,13 +2,13 @@ PDOStatements and multi query --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function mysql_stmt_multiquery_wrong_usage($db) { @@ -53,7 +53,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_nextrowset.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_nextrowset.phpt index e971ce9513..c5e66cf18a 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_nextrowset.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_nextrowset.phpt @@ -4,8 +4,8 @@ MySQL PDOStatement->nextRowSet() nextRowset() problem with stored proc & emulation mode & mysqlnd --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); $row = $db->query('SELECT VERSION() as _version')->fetch(PDO::FETCH_ASSOC); @@ -23,7 +23,7 @@ if (!MySQLPDOTest::isPDOMySQLnd()) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true); @@ -110,7 +110,7 @@ if (!MySQLPDOTest::isPDOMySQLnd()) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_rowcount.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_rowcount.phpt index 1e89c8900c..713945e98d 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_rowcount.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_rowcount.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->rowCount() @ SELECT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); MySQLPDOTest::createTestTable($db); @@ -29,7 +29,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECT-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_unbuffered_2050.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_unbuffered_2050.phpt index 1dc203fa9e..35d4ba3cba 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_unbuffered_2050.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_unbuffered_2050.phpt @@ -2,8 +2,8 @@ MySQL PDO:query() vs. PDO::prepare() and MySQL error 2050 --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); if (MYSQLPDOTest::isPDOMySQLnd()) @@ -11,7 +11,7 @@ if (MYSQLPDOTest::isPDOMySQLnd()) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); try { @@ -112,7 +112,7 @@ if (MYSQLPDOTest::isPDOMySQLnd()) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; MySQLPDOTest::dropTestTable(); ?> --EXPECTF-- diff --git a/ext/pdo_mysql/tests/pdo_mysql_stmt_variable_columncount.phpt b/ext/pdo_mysql/tests/pdo_mysql_stmt_variable_columncount.phpt index 02f8c682b2..e1b57a753e 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_stmt_variable_columncount.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_stmt_variable_columncount.phpt @@ -4,8 +4,8 @@ MySQL Prepared Statements and different column counts nextRowset() problem with stored proc & emulation mode & mysqlnd --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); $db = MySQLPDOTest::factory(); @@ -21,7 +21,7 @@ if ($version < 50000) ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); $db = MySQLPDOTest::factory(); function check_result($offset, $stmt, $columns) { diff --git a/ext/pdo_mysql/tests/pdo_mysql_subclass.phpt b/ext/pdo_mysql/tests/pdo_mysql_subclass.phpt index 773537b12c..915df7d69f 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_subclass.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_subclass.phpt @@ -2,13 +2,13 @@ MySQL PDOStatement->execute()/fetch(), Non-SELECT --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); // No silly strict mode warnings, please! error_reporting(E_ALL^E_STRICT); @@ -74,7 +74,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_types.phpt b/ext/pdo_mysql/tests/pdo_mysql_types.phpt index 7fb9fe51ed..fee1aff514 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_types.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_types.phpt @@ -2,13 +2,13 @@ MySQL PDO->exec(), native types wo ZEROFILL --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function test_type(&$db, $offset, $sql_type, $value, $ret_value = NULL, $pattern = NULL, $alternative_type = NULL) { @@ -176,7 +176,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pdo_mysql_types_zerofill.phpt b/ext/pdo_mysql/tests/pdo_mysql_types_zerofill.phpt index 1d8c529378..1ef5ab1370 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_types_zerofill.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_types_zerofill.phpt @@ -2,13 +2,13 @@ MySQL PDO->exec(), native types - ZEROFILL --SKIPIF-- <?php -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); -require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'skipif.inc'); +require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); MySQLPDOTest::skip(); ?> --FILE-- <?php - require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); + require_once(__DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc'); function test_type(&$db, $offset, $sql_type, $value, $ret_value = NULL, $pattern = NULL) { @@ -120,7 +120,7 @@ MySQLPDOTest::skip(); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pecl_bug_5200.phpt b/ext/pdo_mysql/tests/pecl_bug_5200.phpt index ff5b0e4c3e..d44a5c2282 100644 --- a/ext/pdo_mysql/tests/pecl_bug_5200.phpt +++ b/ext/pdo_mysql/tests/pecl_bug_5200.phpt @@ -3,14 +3,14 @@ PDO MySQL PECL Bug #5200 (Describe table gives unexpected result mysql and type --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__). '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__. '/common.phpt'); $db->exec("CREATE TABLE test (bar INT NOT NULL, phase enum('please_select', 'I', 'II', 'IIa', 'IIb', 'III', 'IV'))"); @@ -20,7 +20,7 @@ foreach ($db->query('DESCRIBE test phase')->fetchAll(PDO::FETCH_ASSOC) as $row) ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/pecl_bug_5780.phpt b/ext/pdo_mysql/tests/pecl_bug_5780.phpt index 95c82d7603..6838cebd37 100644 --- a/ext/pdo_mysql/tests/pecl_bug_5780.phpt +++ b/ext/pdo_mysql/tests/pecl_bug_5780.phpt @@ -3,14 +3,14 @@ PDO MySQL PECL Bug #5780 (Failure to produce an error when one is expected) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__). '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__. '/common.phpt'); $db->exec("CREATE TABLE test (login varchar(32) NOT NULL, data varchar(64) NOT NULL)"); $db->exec("CREATE TABLE test2 (login varchar(32) NOT NULL, password varchar(64) NOT NULL)"); @@ -28,7 +28,7 @@ var_dump($info); ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); $db->exec('DROP TABLE IF EXISTS test2'); diff --git a/ext/pdo_mysql/tests/pecl_bug_5802.phpt b/ext/pdo_mysql/tests/pecl_bug_5802.phpt index 1eec07fa04..01e95343c6 100644 --- a/ext/pdo_mysql/tests/pecl_bug_5802.phpt +++ b/ext/pdo_mysql/tests/pecl_bug_5802.phpt @@ -3,14 +3,14 @@ PDO MySQL PECL Bug #5802 (bindParam/bindValue retain the is_null flag) --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__). '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__. '/common.phpt'); $db->exec('create table test ( bar char(3) NULL )'); $stmt = $db->prepare('insert into test (bar) values(:bar)') or var_dump($db->errorInfo()); @@ -36,7 +36,7 @@ print "done!"; ?> --CLEAN-- <?php -require dirname(__FILE__) . '/mysql_pdo_test.inc'; +require __DIR__ . '/mysql_pdo_test.inc'; $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> diff --git a/ext/pdo_mysql/tests/show_tables.phpt b/ext/pdo_mysql/tests/show_tables.phpt index 1b1ef67680..d6b1337412 100644 --- a/ext/pdo_mysql/tests/show_tables.phpt +++ b/ext/pdo_mysql/tests/show_tables.phpt @@ -3,14 +3,14 @@ PDO MySQL SHOW TABLES --SKIPIF-- <?php if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded'); -require dirname(__FILE__) . '/config.inc'; -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; +require __DIR__ . '/config.inc'; +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; PDOTest::skip(); ?> --FILE-- <?php -require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc'; -$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt'); +require __DIR__ . '/../../../ext/pdo/tests/pdo_test.inc'; +$db = PDOTest::test_factory(__DIR__ . '/common.phpt'); print_r($db->query('SHOW TABLES')); --EXPECT-- |
