/**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     parent::setUp();
     $this->drupalLogin($this->adminUser);
     $this->createContentTypeFromUi('Moderated content', 'moderated_content', TRUE, ['draft', 'needs_review', 'published'], 'draft');
     $this->grantUserPermissionToCreateContentOfType($this->adminUser, 'moderated_content');
 }
 /**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     parent::setUp();
     // Create the "basic" block type.
     $bundle = BlockContentType::create(['id' => 'basic', 'label' => 'basic', 'revision' => FALSE]);
     $bundle->save();
     // Add the body field to it.
     block_content_add_body_field($bundle->id());
 }