You are here

public function WorkflowCollectorTest::testWorkflowCollection in Workbench Moderation to Content Moderation 8.2

File

tests/src/Kernel/WorkflowCollectorTest.php, line 100

Class

WorkflowCollectorTest
@covers \Drupal\wbm2cm\WorkflowCollector @group wbm2cm

Namespace

Drupal\Tests\wbm2cm\Kernel

Code

public function testWorkflowCollection() {
  $modules = [
    'content_moderation',
    'workflows',
  ];
  $this
    ->enableModules($modules);
  wbm2cm_modules_installed($modules);
  $this
    ->assertSame(3, \Drupal::entityQuery('workflow')
    ->count()
    ->execute());
  return;
  $this
    ->assertWorkflow('article__page', [
    'page',
    'article',
  ], [
    'archived',
    'draft',
    'review',
    'published',
  ], [
    'legal_review',
    'postponed',
  ], [
    'archived_draft',
    'draft_draft',
    'draft_review',
    'review_draft',
    'review_published',
    'published_draft',
    'published_archived',
  ], [
    'review_legal_review',
    'legal_review_draft',
    'legal_review_published',
  ]);
  $this
    ->assertWorkflow('press_release', [
    'press_release',
  ], [
    'archived',
    'draft',
    'review',
    'legal_review',
    'postponed',
    'published',
  ], [], [
    'archived_draft',
    'draft_draft',
    'draft_review',
    'review_draft',
    'review_legal_review',
    'legal_review_draft',
    'review_published',
    'legal_review_published',
    'published_archived',
    'published_draft',
  ], []);
}