Merge "MovePage methods need to run safety checks"
[lhc/web/wiklou.git] / tests / parser / TestFileReader.php
index a96485d..307bbb6 100644 (file)
@@ -28,7 +28,6 @@ class TestFileReader {
        private $sectionLineNum = [];
        private $lineNum = 0;
        private $runDisabled;
-       private $runParsoid;
        private $regex;
 
        private $articles = [];
@@ -66,11 +65,9 @@ class TestFileReader {
 
                $options = $options + [
                        'runDisabled' => false,
-                       'runParsoid' => false,
                        'regex' => '//',
                ];
                $this->runDisabled = $options['runDisabled'];
-               $this->runParsoid = $options['runParsoid'];
                $this->regex = $options['regex'];
        }
 
@@ -112,13 +109,6 @@ class TestFileReader {
                        }
                }
 
-               if ( preg_match( '/\\bparsoid\\b/i', $data['options'] ) && $nonTidySection === 'html'
-                       && !$this->runParsoid
-               ) {
-                       // A test which normally runs on Parsoid but can optionally be run with MW
-                       return;
-               }
-
                if ( !preg_match( $this->regex, $data['test'] ) ) {
                        // Filtered test
                        return;
@@ -165,7 +155,7 @@ class TestFileReader {
        }
 
        private function execute() {
-               while ( false !== ( $line = fgets( $this->fh ) ) ) {
+               while ( ( $line = fgets( $this->fh ) ) !== false ) {
                        $this->lineNum++;
                        $matches = [];