function ShortcutSetValidationTest::setUp

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

Overrides ConfigEntityValidationTestBase::setUp

File

core/modules/shortcut/tests/src/Kernel/ShortcutSetValidationTest.php, line 25

Class

ShortcutSetValidationTest
Tests validation of shortcut_set entities.

Namespace

Drupal\Tests\shortcut\Kernel

Code

protected function setUp() : void {
    parent::setUp();
    $this->installConfig('shortcut');
    $this->installEntitySchema('shortcut');
    $this->entity = ShortcutSet::create([
        'id' => 'test-shortcut-set',
        'label' => 'Test',
    ]);
    $this->entity
        ->save();
}

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