function ConfigOtherModuleTest::getStorage

Gets the provided entity type's storage.

Parameters

string $entity_type_id: (optional) The entity type ID to get a storage for. Defaults to 'config_test'.

Return value

\Drupal\Core\Entity\EntityStorageInterface The entity type's storage.

File

core/modules/config/tests/src/Functional/ConfigOtherModuleTest.php, line 150

Class

ConfigOtherModuleTest
Tests default configuration provided by a module that does not own it.

Namespace

Drupal\Tests\config\Functional

Code

protected function getStorage($entity_type_id = 'config_test') {
  return \Drupal::entityTypeManager()->getStorage($entity_type_id);
}

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