diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php index 8206618..2628951 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php @@ -28,11 +28,7 @@ protected function setUp() { parent::setUp(); entity_create('node_type', array('type' => 'page'))->save(); entity_create('node_type', array('type' => 'story'))->save(); - $this->container->get('entity.manager')->getStorage('comment_type')->create(array( - 'id' => 'comment', - 'label' => 'comment', - 'target_entity_type_id' => 'node', - ))->save(); + \Drupal::service('comment.manager')->addDefaultField('node', 'story'); $this->container->get('entity.manager')->getStorage('comment_type')->create(array( 'id' => 'comment_no_subject', 'label' => 'comment_no_subject', @@ -55,7 +51,6 @@ protected function setUp() { ); $this->prepareMigrations($id_mappings); - \Drupal::service('comment.manager')->addDefaultField('node', 'story'); /** @var \Drupal\migrate\entity\Migration $migration */ $migration = entity_load('migration', 'd6_comment');