use Drupal\node\Entity\Node;
use Drupal\node\Entity\NodeType;
+use Drupal\Tests\content_moderation\Traits\ContentModerationTestTrait;
use Drupal\Tests\views\Kernel\ViewsKernelTestBase;
use Drupal\views\Views;
-use Drupal\workflows\Entity\Workflow;
/**
* Tests the views integration of content_moderation.
*/
class ViewsDataIntegrationTest extends ViewsKernelTestBase {
+ use ContentModerationTestTrait;
+
/**
* {@inheritdoc}
*/
'type' => 'page',
]);
$node_type->save();
- $workflow = Workflow::load('editorial');
+ $workflow = $this->createEditorialWorkflow();
$workflow->getTypePlugin()->addEntityTypeAndBundle('node', 'page');
$workflow->getTypePlugin()->addEntityTypeAndBundle('entity_test_mulrevpub', 'entity_test_mulrevpub');
$workflow->save();