You are here

protected function FormatterTest::setUp in Scheduled Publish 8.2

Same name and namespace in other branches
  1. 8.3 tests/src/Kernel/FormatterTest.php \Drupal\Tests\scheduled_publish\Kernel\FormatterTest::setUp()

Set the default field storage backend for fields created during tests.

Overrides FieldKernelTestBase::setUp

File

tests/src/Kernel/FormatterTest.php, line 42

Class

FormatterTest
Class FormatterTest

Namespace

Drupal\Tests\scheduled_publish\Kernel

Code

protected function setUp() {
  parent::setUp();
  $this
    ->setInstallProfile('standard');
  $this
    ->installConfig([
    'field',
    'system',
    'content_moderation',
    'scheduled_publish',
  ]);
  $this
    ->installEntitySchema('node');
  $this
    ->installEntitySchema('user');
  $this
    ->installSchema('node', 'node_access');
  $this
    ->installEntitySchema('user');
  $this
    ->installEntitySchema('content_moderation_state');
  $this
    ->installConfig('content_moderation');
  $this->scheduledUpdateService = \Drupal::service('scheduled_publish.update');
  $this
    ->createNodeType();
}