function EntityApiInfoTest::testEntityInfoCacheWatchdog

Tests entity info cache after enabling a module with a dependency on an entity providing module.

See also

entity_cache_test_watchdog()

File

drupal/core/modules/system/lib/Drupal/system/Tests/Entity/EntityApiInfoTest.php, line 53
Definition of Drupal\system\Tests\Entity\EntityApiInfoTest.

Class

EntityApiInfoTest
Tests Entity API base functionality.

Namespace

Drupal\system\Tests\Entity

Code

function testEntityInfoCacheWatchdog() {
  module_enable(array(
    'entity_cache_test',
  ));
  $info = state()
    ->get('entity_cache_test');
  $this
    ->assertEqual($info['label'], 'Entity Cache Test', 'Entity info label is correct.');
  $this
    ->assertEqual($info['controller_class'], 'Drupal\\Core\\Entity\\DatabaseStorageController', 'Entity controller class info is correct.');
}