<?php
-require __DIR__.'/../../maintenance/Maintenance.php';
+require __DIR__ . '/../../maintenance/Maintenance.php';
define( 'MW_PARSER_TEST', true );
}
protected function setupFileData() {
- global $wgParserTestFiles;
$this->testFiles = [];
$this->testCount = 0;
- foreach ( $wgParserTestFiles as $file ) {
+ foreach ( ParserTestRunner::getParserTestFiles() as $file ) {
$fileInfo = TestFileReader::read( $file );
$this->testFiles[$file] = $fileInfo;
$this->testCount += count( $fileInfo['tests'] );
print "Wrote updated file\n";
} else {
print "Cannot write updated file, here is a patch you can paste:\n\n";
- print
- "--- {$fileName}\n" .
+ print "--- {$fileName}\n" .
"+++ {$fileName}~\n" .
$this->unifiedDiff( $text, $result ) .
"\n";