Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / menu_ui / tests / src / Functional / MenuUiContentModerationTest.php
index be018f4ce113ed2beda8e067bd5006ab42805c48..b5d4b43c8224dc8824cc2bbfb58855bf1d8641e2 100644 (file)
@@ -3,7 +3,7 @@
 namespace Drupal\Tests\menu_ui\Functional;
 
 use Drupal\Tests\BrowserTestBase;
-use Drupal\workflows\Entity\Workflow;
+use Drupal\Tests\content_moderation\Traits\ContentModerationTestTrait;
 
 /**
  * Tests Menu UI and Content Moderation integration.
@@ -12,6 +12,8 @@ use Drupal\workflows\Entity\Workflow;
  */
 class MenuUiContentModerationTest extends BrowserTestBase {
 
+  use ContentModerationTestTrait;
+
   /**
    * Modules to install.
    *
@@ -34,7 +36,7 @@ class MenuUiContentModerationTest extends BrowserTestBase {
       'display_submitted' => FALSE,
     ]);
 
-    $workflow = Workflow::load('editorial');
+    $workflow = $this->createEditorialWorkflow();
     $workflow->getTypePlugin()->addEntityTypeAndBundle('node', 'page');
     $workflow->save();
   }