diff options
author | Peter Kokot <peterkokot@gmail.com> | 2019-03-15 23:36:47 +0100 |
---|---|---|
committer | Peter Kokot <peterkokot@gmail.com> | 2019-03-15 23:36:47 +0100 |
commit | 6426420f61de0df32a6085924d25b347c8788363 (patch) | |
tree | ef32814ffbea0ad3c3c38a942f9751302606c736 /ext/xsl | |
parent | f26c8644bb340e9e7abb6d1cedb091e9d87dd1d4 (diff) | |
parent | 26dfce7f36d1c6f737ac241df1315a1b42b932c7 (diff) | |
download | php-git-6426420f61de0df32a6085924d25b347c8788363.tar.gz |
Merge branch 'PHP-7.4'
* PHP-7.4:
Replace dirname(__FILE__) by __DIR__ in tests
Diffstat (limited to 'ext/xsl')
34 files changed, 62 insertions, 62 deletions
diff --git a/ext/xsl/tests/bug26384.phpt b/ext/xsl/tests/bug26384.phpt index b6d2940ae6..54ff5e767d 100644 --- a/ext/xsl/tests/bug26384.phpt +++ b/ext/xsl/tests/bug26384.phpt @@ -1,17 +1,17 @@ --TEST-- Bug #26384 (domxslt->process causes segfault with xsl:key) --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php $dom = new domDocument; -$dom->load(dirname(__FILE__)."/area_name.xml"); +$dom->load(__DIR__."/area_name.xml"); if(!$dom) { echo "Error while parsing the document\n"; exit; } $xsl = new domDocument; -$xsl->load(dirname(__FILE__)."/area_list.xsl"); +$xsl->load(__DIR__."/area_list.xsl"); if(!$xsl) { echo "Error while parsing the document\n"; exit; diff --git a/ext/xsl/tests/bug53965.phpt b/ext/xsl/tests/bug53965.phpt index 40ce0a62f1..7feee0e053 100644 --- a/ext/xsl/tests/bug53965.phpt +++ b/ext/xsl/tests/bug53965.phpt @@ -7,7 +7,7 @@ if (!extension_loaded('xsl')) die("skip Extension XSL is required\n"); --FILE-- <?php -$base = 'file://' . dirname(__FILE__) . DIRECTORY_SEPARATOR . '53965'; +$base = 'file://' . __DIR__ . DIRECTORY_SEPARATOR . '53965'; $xml = new DOMDocument(); $xml->load($base . DIRECTORY_SEPARATOR . 'collection.xml'); diff --git a/ext/xsl/tests/bug54446.phpt b/ext/xsl/tests/bug54446.phpt index 2335319009..b9af5581eb 100644 --- a/ext/xsl/tests/bug54446.phpt +++ b/ext/xsl/tests/bug54446.phpt @@ -8,7 +8,7 @@ if (!extension_loaded('xsl')) die("skip Extension XSL is required\n"); <?php include("prepare.inc"); -$outputfile = dirname(__FILE__)."/bug54446test.txt"; +$outputfile = __DIR__."/bug54446test.txt"; if (file_exists($outputfile)) { unlink($outputfile); } diff --git a/ext/xsl/tests/bug54446_with_ini.phpt b/ext/xsl/tests/bug54446_with_ini.phpt index 92a71cad09..9769d1fd29 100644 --- a/ext/xsl/tests/bug54446_with_ini.phpt +++ b/ext/xsl/tests/bug54446_with_ini.phpt @@ -8,7 +8,7 @@ if (!extension_loaded('xsl')) die("skip Extension XSL is required\n"); <?php include("prepare.inc"); -$outputfile = dirname(__FILE__)."/bug54446test.txt"; +$outputfile = __DIR__."/bug54446test.txt"; if (file_exists($outputfile)) { unlink($outputfile); } diff --git a/ext/xsl/tests/xslt001.phpt b/ext/xsl/tests/xslt001.phpt index 70d4446928..f7bdc42424 100644 --- a/ext/xsl/tests/xslt001.phpt +++ b/ext/xsl/tests/xslt001.phpt @@ -1,7 +1,7 @@ --TEST-- Test 1: Transform To XML String --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 1: Transform To XML String"; diff --git a/ext/xsl/tests/xslt002.phpt b/ext/xsl/tests/xslt002.phpt index deb86aa215..60a8ec0e16 100644 --- a/ext/xsl/tests/xslt002.phpt +++ b/ext/xsl/tests/xslt002.phpt @@ -1,7 +1,7 @@ --TEST-- Test 2: Transform To HTML String --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 2: Transform To HTML String"; diff --git a/ext/xsl/tests/xslt003.phpt b/ext/xsl/tests/xslt003.phpt index 992e5c7cf0..d1ad8a6496 100644 --- a/ext/xsl/tests/xslt003.phpt +++ b/ext/xsl/tests/xslt003.phpt @@ -1,7 +1,7 @@ --TEST-- Test 3: Using Parameters --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 3: Using Parameters"; diff --git a/ext/xsl/tests/xslt004.phpt b/ext/xsl/tests/xslt004.phpt index e2076032a9..656c99086d 100644 --- a/ext/xsl/tests/xslt004.phpt +++ b/ext/xsl/tests/xslt004.phpt @@ -1,7 +1,7 @@ --TEST-- Test 4: Checking UTF8 Output --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 4: Checking UTF8 Output"; diff --git a/ext/xsl/tests/xslt005.phpt b/ext/xsl/tests/xslt005.phpt index 49027e1b16..28da4db734 100644 --- a/ext/xsl/tests/xslt005.phpt +++ b/ext/xsl/tests/xslt005.phpt @@ -1,7 +1,7 @@ --TEST-- Test 5: Checking Indent --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 5: Checking Indent"; diff --git a/ext/xsl/tests/xslt006.phpt b/ext/xsl/tests/xslt006.phpt index 60ca1812e3..0ad976ee69 100644 --- a/ext/xsl/tests/xslt006.phpt +++ b/ext/xsl/tests/xslt006.phpt @@ -1,7 +1,7 @@ --TEST-- Test 6: Transform To Doc --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 6: Transform To Doc"; diff --git a/ext/xsl/tests/xslt007.phpt b/ext/xsl/tests/xslt007.phpt index bb4d0ba657..241cc1cc0b 100644 --- a/ext/xsl/tests/xslt007.phpt +++ b/ext/xsl/tests/xslt007.phpt @@ -1,16 +1,16 @@ --TEST-- Test 7: Transform To Uri --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 7: Transform To Uri"; include("prepare.inc"); $proc->importStylesheet($xsl); print "\n"; -$doc = $proc->transformToUri($dom, "file://".dirname(__FILE__)."/out.xml"); -print file_get_contents(dirname(__FILE__)."/out.xml"); -unlink(dirname(__FILE__)."/out.xml"); +$doc = $proc->transformToUri($dom, "file://".__DIR__."/out.xml"); +print file_get_contents(__DIR__."/out.xml"); +unlink(__DIR__."/out.xml"); print "\n"; --EXPECT-- Test 7: Transform To Uri diff --git a/ext/xsl/tests/xslt008-mb.phpt b/ext/xsl/tests/xslt008-mb.phpt index 52940cecd3..a10b13a580 100644 --- a/ext/xsl/tests/xslt008-mb.phpt +++ b/ext/xsl/tests/xslt008-mb.phpt @@ -2,7 +2,7 @@ Test 8: Stream Wrapper Includes --SKIPIF-- <?php - require_once dirname(__FILE__) .'/skipif.inc'; + require_once __DIR__ .'/skipif.inc'; if (!extension_loaded('zlib')) die('skip zlib extension not available'); ?> --FILE-- @@ -10,12 +10,12 @@ Test 8: Stream Wrapper Includes echo "Test 8: Stream Wrapper Includes "; include("prepare.inc"); $xsl = new domDocument; -$xsl->load(dirname(__FILE__)."/私はガラスを食べられますstreamsinclude.xsl"); +$xsl->load(__DIR__."/私はガラスを食べられますstreamsinclude.xsl"); if(!$xsl) { echo "Error while parsing the document\n"; exit; } -chdir(dirname(__FILE__)); +chdir(__DIR__); $proc->importStylesheet($xsl); print "\n"; print $proc->transformToXML($dom); diff --git a/ext/xsl/tests/xslt008.phpt b/ext/xsl/tests/xslt008.phpt index 4c72bf81c3..4446045198 100644 --- a/ext/xsl/tests/xslt008.phpt +++ b/ext/xsl/tests/xslt008.phpt @@ -2,7 +2,7 @@ Test 8: Stream Wrapper Includes --SKIPIF-- <?php - require_once dirname(__FILE__) .'/skipif.inc'; + require_once __DIR__ .'/skipif.inc'; if (!extension_loaded('zlib')) die('skip zlib extension not available'); ?> --FILE-- @@ -10,12 +10,12 @@ Test 8: Stream Wrapper Includes echo "Test 8: Stream Wrapper Includes "; include("prepare.inc"); $xsl = new domDocument; -$xsl->load(dirname(__FILE__)."/streamsinclude.xsl"); +$xsl->load(__DIR__."/streamsinclude.xsl"); if(!$xsl) { echo "Error while parsing the document\n"; exit; } -chdir(dirname(__FILE__)); +chdir(__DIR__); $proc->importStylesheet($xsl); print "\n"; print $proc->transformToXML($dom); diff --git a/ext/xsl/tests/xslt009.phpt b/ext/xsl/tests/xslt009.phpt index b4e8390985..429e11f10d 100644 --- a/ext/xsl/tests/xslt009.phpt +++ b/ext/xsl/tests/xslt009.phpt @@ -2,7 +2,7 @@ Test 9: Stream Wrapper XPath-Document() --SKIPIF-- <?php - require_once dirname(__FILE__) .'/skipif.inc'; + require_once __DIR__ .'/skipif.inc'; if (!extension_loaded('zlib')) die('skip zlib extension not available'); ?> --FILE-- @@ -11,7 +11,7 @@ echo "Test 9: Stream Wrapper XPath-Document()"; include("prepare.inc"); $xsl = new domDocument; -$xsl->load(dirname(__FILE__)."/documentxpath.xsl"); +$xsl->load(__DIR__."/documentxpath.xsl"); if(!$xsl) { echo "Error while parsing the document\n"; exit; diff --git a/ext/xsl/tests/xslt010.phpt b/ext/xsl/tests/xslt010.phpt index aeedabc513..dc1eac3ccb 100644 --- a/ext/xsl/tests/xslt010.phpt +++ b/ext/xsl/tests/xslt010.phpt @@ -2,7 +2,7 @@ Test 10: EXSLT Support --SKIPIF-- <?php -require_once dirname(__FILE__) .'/skipif.inc'; +require_once __DIR__ .'/skipif.inc'; $proc = new xsltprocessor; if (!$proc->hasExsltSupport()) die('skip EXSLT support not available'); if (LIBXSLT_VERSION < 10117) die('skip too old libxsl'); @@ -13,12 +13,12 @@ if (LIBXSLT_VERSION > 10129) die('skip for libxsl < 10130'); echo "Test 10: EXSLT Support"; $dom = new domDocument(); - $dom->load(dirname(__FILE__)."/exslt.xsl"); + $dom->load(__DIR__."/exslt.xsl"); $proc = new xsltprocessor; $xsl = $proc->importStylesheet($dom); $xml = new DomDocument(); - $xml->load(dirname(__FILE__)."/exslt.xml"); + $xml->load(__DIR__."/exslt.xml"); print $proc->transformToXml($xml); --EXPECT-- diff --git a/ext/xsl/tests/xslt010_gt10129.phpt b/ext/xsl/tests/xslt010_gt10129.phpt index 999ec807a3..d1de1722a1 100644 --- a/ext/xsl/tests/xslt010_gt10129.phpt +++ b/ext/xsl/tests/xslt010_gt10129.phpt @@ -2,7 +2,7 @@ Test 10: EXSLT Support --SKIPIF-- <?php -require_once dirname(__FILE__) .'/skipif.inc'; +require_once __DIR__ .'/skipif.inc'; $proc = new xsltprocessor; if (!$proc->hasExsltSupport()) die('skip EXSLT support not available'); if (LIBXSLT_VERSION < 10130) die('skip too old libxsl'); @@ -12,12 +12,12 @@ if (LIBXSLT_VERSION < 10130) die('skip too old libxsl'); echo "Test 10: EXSLT Support"; $dom = new domDocument(); - $dom->load(dirname(__FILE__)."/exslt.xsl"); + $dom->load(__DIR__."/exslt.xsl"); $proc = new xsltprocessor; $xsl = $proc->importStylesheet($dom); $xml = new DomDocument(); - $xml->load(dirname(__FILE__)."/exslt.xml"); + $xml->load(__DIR__."/exslt.xml"); print $proc->transformToXml($xml); --EXPECT-- diff --git a/ext/xsl/tests/xslt011.phpt b/ext/xsl/tests/xslt011.phpt index 92777b8a56..5eaa7fbd09 100644 --- a/ext/xsl/tests/xslt011.phpt +++ b/ext/xsl/tests/xslt011.phpt @@ -1,7 +1,7 @@ --TEST-- Test 11: php:function Support --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php print "Test 11: php:function Support\n"; @@ -11,12 +11,12 @@ print "Test 11: php:function Support\n"; } $dom = new domDocument(); - $dom->load(dirname(__FILE__)."/xslt011.xsl"); + $dom->load(__DIR__."/xslt011.xsl"); $proc = new xsltprocessor; $xsl = $proc->importStylesheet($dom); $xml = new DomDocument(); - $xml->load(dirname(__FILE__)."/xslt011.xml"); + $xml->load(__DIR__."/xslt011.xml"); $proc->registerPHPFunctions(); print $proc->transformToXml($xml); diff --git a/ext/xsl/tests/xslt012.phpt b/ext/xsl/tests/xslt012.phpt index 6cb3f5ec71..a24a0d2a7f 100644 --- a/ext/xsl/tests/xslt012.phpt +++ b/ext/xsl/tests/xslt012.phpt @@ -1,20 +1,20 @@ --TEST-- Test 12: Using Associative Array of Parameters --SKIPIF-- -<?php require_once dirname(__FILE__) .'/skipif.inc'; ?> +<?php require_once __DIR__ .'/skipif.inc'; ?> --FILE-- <?php echo "Test 12: Using Associative Array of Parameters"; $dom = new domDocument; -$dom->load(dirname(__FILE__)."/xslt.xml"); +$dom->load(__DIR__."/xslt.xml"); if(!$dom) { echo "Error while parsing the document\n"; exit; } $xsl = new domDocument; -$xsl->load(dirname(__FILE__)."/xslt012.xsl"); +$xsl->load(__DIR__."/xslt012.xsl"); if(!$xsl) { echo "Error while parsing the document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_getParameter-invalidparam.phpt b/ext/xsl/tests/xsltprocessor_getParameter-invalidparam.phpt index 41bcf4ad10..78191c2b6e 100644 --- a/ext/xsl/tests/xsltprocessor_getParameter-invalidparam.phpt +++ b/ext/xsl/tests/xsltprocessor_getParameter-invalidparam.phpt @@ -8,7 +8,7 @@ Check xsltprocessor::getParameter with undefined parameter ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; var_dump($proc->getParameter('', 'doesnotexist')); --EXPECT-- bool(false) diff --git a/ext/xsl/tests/xsltprocessor_getParameter.phpt b/ext/xsl/tests/xsltprocessor_getParameter.phpt index b4031db975..6512b7b53e 100644 --- a/ext/xsl/tests/xsltprocessor_getParameter.phpt +++ b/ext/xsl/tests/xsltprocessor_getParameter.phpt @@ -8,7 +8,7 @@ Check xsltprocessor::getparameter functionality ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $proc->importStylesheet($xsl); $proc->setParameter('', 'key', 'value'); var_dump($proc->getParameter('', 'key')); diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-allfuncs.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-allfuncs.phpt index f61b7abe89..18e7ddca97 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-allfuncs.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-allfuncs.phpt @@ -8,9 +8,9 @@ Check xsltprocessor::registerPHPFunctions ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-multiple.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-multiple.phpt index 9879fb38f7..ab136735ef 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-multiple.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-multiple.phpt @@ -12,9 +12,9 @@ list - it does not replace the previously allowed functions. ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-notallowed.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-notallowed.phpt index cc49371fe6..03b3f744e6 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-notallowed.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array-notallowed.phpt @@ -8,9 +8,9 @@ Check xsltprocessor::registerPHPFunctions with array and a not allowed function ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array.phpt index 642b58e74a..5cfa497408 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-array.phpt @@ -8,9 +8,9 @@ Check xsltprocessor::registerPHPFunctions with array ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt index f66632d2be..e173842c4e 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt @@ -11,9 +11,9 @@ is expected to fail ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc-nostring.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc-nostring.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt index e4cf0e816a..85fcbe0d02 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt @@ -10,9 +10,9 @@ The XSL script tries to call a php function that is not defined ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc-undef.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc-undef.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-null.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-null.phpt index a142dfa431..3fb495d5a2 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-null.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-null.phpt @@ -12,9 +12,9 @@ list - it does not replace the previously allowed functions. ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-multiple.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-multiple.phpt index 5eeb793ed5..1ef40abc94 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-multiple.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-multiple.phpt @@ -12,9 +12,9 @@ list - it does not replace the old function. ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-notallowed.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-notallowed.phpt index 1e7092c8bd..cb6a274905 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-notallowed.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string-notallowed.phpt @@ -8,9 +8,9 @@ Check xsltprocessor::registerPHPFunctions with string and not allowed function ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string.phpt index 2a3474eee3..ac9d4ffb9f 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-string.phpt @@ -8,9 +8,9 @@ Check xsltprocessor::registerPHPFunctions with string ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $phpfuncxsl = new domDocument(); -$phpfuncxsl->load(dirname(__FILE__)."/phpfunc.xsl"); +$phpfuncxsl->load(__DIR__."/phpfunc.xsl"); if(!$phpfuncxsl) { echo "Error while parsing the xsl document\n"; exit; diff --git a/ext/xsl/tests/xsltprocessor_removeParameter-invalidparam.phpt b/ext/xsl/tests/xsltprocessor_removeParameter-invalidparam.phpt index a5a62286c1..9eed0ccedc 100644 --- a/ext/xsl/tests/xsltprocessor_removeParameter-invalidparam.phpt +++ b/ext/xsl/tests/xsltprocessor_removeParameter-invalidparam.phpt @@ -8,7 +8,7 @@ Check xsltprocessor::removeParameter with invalid parameter ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $proc->importStylesheet($xsl); var_dump($proc->removeParameter('', 'doesnotexist')); --EXPECT-- diff --git a/ext/xsl/tests/xsltprocessor_removeParameter.phpt b/ext/xsl/tests/xsltprocessor_removeParameter.phpt index 6568e2bae3..6b9cb99d09 100644 --- a/ext/xsl/tests/xsltprocessor_removeParameter.phpt +++ b/ext/xsl/tests/xsltprocessor_removeParameter.phpt @@ -8,7 +8,7 @@ Check xsltprocessor::removeParameter functionality ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $proc->importStylesheet($xsl); $proc->setParameter('', 'key', 'value'); $proc->removeParameter('', 'key'); diff --git a/ext/xsl/tests/xsltprocessor_setparameter-errorquote.phpt b/ext/xsl/tests/xsltprocessor_setparameter-errorquote.phpt index a3114bb755..efefe0f83b 100644 --- a/ext/xsl/tests/xsltprocessor_setparameter-errorquote.phpt +++ b/ext/xsl/tests/xsltprocessor_setparameter-errorquote.phpt @@ -10,7 +10,7 @@ Memleak: http://bugs.php.net/bug.php?id=48221 ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $proc->importStylesheet($xsl); $proc->setParameter('', '', '"\''); $proc->transformToXml($dom); diff --git a/ext/xsl/tests/xsltprocessor_setparameter-nostring.phpt b/ext/xsl/tests/xsltprocessor_setparameter-nostring.phpt index dd17a72d49..2c723434aa 100644 --- a/ext/xsl/tests/xsltprocessor_setparameter-nostring.phpt +++ b/ext/xsl/tests/xsltprocessor_setparameter-nostring.phpt @@ -10,7 +10,7 @@ Memleak: http://bugs.php.net/bug.php?id=48221 ?> --FILE-- <?php -include dirname(__FILE__) .'/prepare.inc'; +include __DIR__ .'/prepare.inc'; $proc->importStylesheet($xsl); var_dump($proc->setParameter('', array(4, 'abc'))); $proc->transformToXml($dom); |