X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fsuites%2FParserTestTopLevelSuite.php;h=28547d1f841c8aec9f842c46147efbf5463d2615;hb=dfbcce91c2ad3269f7f80817beca8571268a999b;hp=cc0f26369e219bd76326ff2e46e4053704caee48;hpb=c0fa6997ae8e544ca25bbe0796e99de6df5144bd;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/suites/ParserTestTopLevelSuite.php b/tests/phpunit/suites/ParserTestTopLevelSuite.php index cc0f26369e..28547d1f84 100644 --- a/tests/phpunit/suites/ParserTestTopLevelSuite.php +++ b/tests/phpunit/suites/ParserTestTopLevelSuite.php @@ -86,7 +86,7 @@ class ParserTestTopLevelSuite extends PHPUnit_Framework_TestSuite { # Filter out .txt files $files = ParserTestRunner::getParserTestFiles(); foreach ( $files as $extName => $parserTestFile ) { - $isCore = ( 0 === strpos( $parserTestFile, $mwTestDir ) ); + $isCore = ( strpos( $parserTestFile, $mwTestDir ) === 0 ); if ( $isCore && $wantsCore ) { self::debug( "included core parser tests: $parserTestFile" ); @@ -113,7 +113,7 @@ class ParserTestTopLevelSuite extends PHPUnit_Framework_TestSuite { $testsName = $extensionName . '__' . basename( $fileName, '.txt' ); $parserTestClassName = ucfirst( $testsName ); - // Official spec for class names: https://secure.php.net/manual/en/language.oop5.basic.php + // Official spec for class names: https://www.php.net/manual/en/language.oop5.basic.php // Prepend 'ParserTest_' to be paranoid about it not starting with a number $parserTestClassName = 'ParserTest_' . preg_replace( '/[^a-zA-Z0-9_\x7f-\xff]/', '_', $parserTestClassName );