You are here

protected function EntityTestBase::applySchemaUpdates in Translation Management Tool 8

Resets caches and applies schema updates.

1 call to EntityTestBase::applySchemaUpdates()
EntityTestBase::createNodeType in src/Tests/EntityTestBase.php
Creates node type with several text fields with different cardinality.

File

src/Tests/EntityTestBase.php, line 233

Class

EntityTestBase
Utility test case class with helper methods to create entities and their fields with populated translatable content. Extend this class if you create tests in which you need Drupal entities and/or fields.

Namespace

Drupal\tmgmt\Tests

Code

protected function applySchemaUpdates() {
  drupal_static_reset();
  \Drupal::entityTypeManager()
    ->clearCachedDefinitions();
  \Drupal::service('router.builder')
    ->rebuild();
  \Drupal::service('entity.definition_update_manager')
    ->applyUpdates();
}