public function InstallTest::testRequiredModuleSchemaVersions in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/system/src/Tests/Module/InstallTest.php \Drupal\system\Tests\Module\InstallTest::testRequiredModuleSchemaVersions()
Tests recorded schema versions of early installed modules in the installer.
File
- core/
modules/ system/ src/ Tests/ Module/ InstallTest.php, line 51 - Contains \Drupal\system\Tests\Module\InstallTest.
Class
- InstallTest
- Tests the installation of modules.
Namespace
Drupal\system\Tests\ModuleCode
public function testRequiredModuleSchemaVersions() {
$version = drupal_get_installed_schema_version('system', TRUE);
$this
->assertTrue($version > 0, 'System module version is > 0.');
$version = drupal_get_installed_schema_version('user', TRUE);
$this
->assertTrue($version > 0, 'User module version is > 0.');
$post_update_key_value = \Drupal::keyValue('post_update');
$existing_updates = $post_update_key_value
->get('existing_updates', []);
$this
->assertTrue(in_array('module_test_post_update_test', $existing_updates));
}