function Drupal6SqlBaseTest::testGetModuleSchemaVersion

Same name in other branches
  1. 9 core/modules/migrate_drupal/tests/src/Unit/source/d6/Drupal6SqlBaseTest.php \Drupal\Tests\migrate_drupal\Unit\source\d6\Drupal6SqlBaseTest::testGetModuleSchemaVersion()
  2. 8.9.x core/modules/migrate_drupal/tests/src/Unit/source/d6/Drupal6SqlBaseTest.php \Drupal\Tests\migrate_drupal\Unit\source\d6\Drupal6SqlBaseTest::testGetModuleSchemaVersion()
  3. 10 core/modules/migrate_drupal/tests/src/Unit/source/d6/Drupal6SqlBaseTest.php \Drupal\Tests\migrate_drupal\Unit\source\d6\Drupal6SqlBaseTest::testGetModuleSchemaVersion()

Tests for Drupal6SqlBase::getModuleSchemaVersion().

File

core/modules/migrate_drupal/tests/src/Unit/source/d6/Drupal6SqlBaseTest.php, line 112

Class

Drupal6SqlBaseTest
Tests the D6 SQL base class.

Namespace

Drupal\Tests\migrate_drupal\Unit\source\d6

Code

public function testGetModuleSchemaVersion() : void {
    // Non-existent module.
    $this->assertFalse($this->base
        ->getModuleSchemaVersionWrapper('module3'));
    // Disabled module should still return schema version.
    $this->assertEquals(7201, $this->base
        ->getModuleSchemaVersionWrapper('module2'));
    // Enabled module.
    $this->assertEquals(-1, $this->base
        ->getModuleSchemaVersionWrapper('module1'));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.