Set migration stages in RevisionStoreDbTestBase
authorTim Starling <tstarling@wikimedia.org>
Mon, 27 Aug 2018 23:39:18 +0000 (09:39 +1000)
committerTim Starling <tstarling@wikimedia.org>
Tue, 28 Aug 2018 05:41:08 +0000 (15:41 +1000)
I confirmed that wgCommentTableSchemaMigrationStage needs to be set, and
getActorQueryFields() implies that the actor table migration stage needs
to be set as well.

Change-Id: I153ff985c8753b291d2201ebeed10515acb0cd36

tests/phpunit/includes/Storage/RevisionStoreDbTestBase.php

index 8137b27..6679754 100644 (file)
@@ -77,15 +77,12 @@ abstract class RevisionStoreDbTestBase extends MediaWikiTestCase {
 
                $this->tablesUsed += $this->getMcrTablesToReset();
 
-               $this->setMwGlobals(
-                       'wgMultiContentRevisionSchemaMigrationStage',
-                       $this->getMcrMigrationStage()
-               );
-
-               $this->setMwGlobals(
-                       'wgContentHandlerUseDB',
-                       $this->getContentHandlerUseDB()
-               );
+               $this->setMwGlobals( [
+                       'wgMultiContentRevisionSchemaMigrationStage' => $this->getMcrMigrationStage(),
+                       'wgContentHandlerUseDB' => $this->getContentHandlerUseDB(),
+                       'wgCommentTableSchemaMigrationStage' => MIGRATION_OLD,
+                       'wgActorTableSchemaMigrationStage' => MIGRATION_OLD,
+               ] );
 
                $this->overrideMwServices();
        }