public function assertWorkflowTransitions(TableNode $expected) {
    $states_info = [];
    foreach ($this->getWorkflows() as $workflow) {

      /** @var \Drupal\workflows\TransitionInterface[] $transitions */
      $transitions = $workflow->getTypePlugin()->getTransitions();
      foreach ($transitions as $transition) {
        foreach ($transition->from() as $from_state) {

          $states_info[] = [
            $workflow->label(),
            $transition->label(),
            $transition->id(),
            $from_state->label(),
            $transition->to()->label(),
          ];
        }

      }
    }
    $actual = new TableNode($states_info);

    (new TableEqualityAssertion($expected, $actual))
      ->expectHeader([
        'Workflow',
        'Label',
        'Machine name',
        'From state',
        'To state',
      ])
      ->ignoreRowOrder()
      ->setMissingRowsLabel(self::missingRowsLabelFor('workflow states'))
      ->setUnexpectedRowsLabel(self::unexpectedRowsLabelFor('workflow states'))
      ->assert();
  }