function ShortcutEntityLinksTest::setUp

Same name and namespace in other branches
  1. main core/modules/shortcut/tests/src/Kernel/ShortcutEntityLinksTest.php \Drupal\Tests\shortcut\Kernel\ShortcutEntityLinksTest::setUp()

Overrides KernelTestBase::setUp

File

core/modules/shortcut/tests/src/Kernel/ShortcutEntityLinksTest.php, line 47

Class

ShortcutEntityLinksTest
Tests the entity_links filter with shortcut entities.

Namespace

Drupal\Tests\shortcut\Kernel

Code

protected function setUp() : void {
  parent::setUp();
  $this->installConfig('system');
  $this->installEntitySchema('user');
  $this->installEntitySchema('shortcut');
  $this->installConfig([
    'shortcut',
  ]);
  /** @var \Drupal\Component\Plugin\PluginManagerInterface $manager */
  $manager = $this->container
    ->get('plugin.manager.filter');
  $bag = new FilterPluginCollection($manager, []);
  $this->filter = $bag->get('entity_links');
}

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