editTests: Use the correct list of parser test files
authorKunal Mehta <legoktm@member.fsf.org>
Fri, 9 Feb 2018 20:08:05 +0000 (12:08 -0800)
committerKunal Mehta <legoktm@member.fsf.org>
Fri, 9 Feb 2018 20:08:05 +0000 (12:08 -0800)
$wgParserTestFiles is deprecated, so this wasn't running the core parser
tests. Using ParserTestRunner::getParserTestFiles() includes everything,
including autodiscovered extension parser tests.

Change-Id: Ie3b02565c184e8e06931ab52a39ca8ae0877aab9

tests/parser/editTests.php

index cb430f2..3e18370 100644 (file)
@@ -62,10 +62,9 @@ class ParserEditTests extends Maintenance {
        }
 
        protected function setupFileData() {
        }
 
        protected function setupFileData() {
-               global $wgParserTestFiles;
                $this->testFiles = [];
                $this->testCount = 0;
                $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'] );
                        $fileInfo = TestFileReader::read( $file );
                        $this->testFiles[$file] = $fileInfo;
                        $this->testCount += count( $fileInfo['tests'] );