You are here

protected function EntityStateChangeValidationTest::setUp in Workbench Moderation 8

Same name and namespace in other branches
  1. 8.2 tests/src/Kernel/EntityStateChangeValidationTest.php \Drupal\Tests\workbench_moderation\Kernel\EntityStateChangeValidationTest::setUp()

Overrides KernelTestBase::setUp

File

tests/src/Kernel/EntityStateChangeValidationTest.php, line 41

Class

EntityStateChangeValidationTest
@coversDefaultClass \Drupal\workbench_moderation\Plugin\Validation\Constraint\ModerationStateValidator @group workbench_moderation

Namespace

Drupal\Tests\workbench_moderation\Kernel

Code

protected function setUp() {
  parent::setUp();
  $this
    ->installSchema('node', 'node_access');
  $this
    ->installSchema('system', [
    'sequences',
  ]);
  $this
    ->installEntitySchema('node');
  $this
    ->installEntitySchema('user');
  $this
    ->installConfig('workbench_moderation');
  $this->adminUser = $this
    ->createUser(array_keys($this->container
    ->get('user.permissions')
    ->getPermissions()));
}