function MigrateCommentFieldInstanceTest::testMigration

Same name in this branch
  1. 8.9.x core/modules/comment/tests/src/Kernel/Migrate/d7/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d7\MigrateCommentFieldInstanceTest::testMigration()
Same name in other branches
  1. 9 core/modules/comment/tests/src/Kernel/Migrate/d6/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d6\MigrateCommentFieldInstanceTest::testMigration()
  2. 9 core/modules/comment/tests/src/Kernel/Migrate/d7/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d7\MigrateCommentFieldInstanceTest::testMigration()
  3. 10 core/modules/comment/tests/src/Kernel/Migrate/d6/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d6\MigrateCommentFieldInstanceTest::testMigration()
  4. 10 core/modules/comment/tests/src/Kernel/Migrate/d7/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d7\MigrateCommentFieldInstanceTest::testMigration()
  5. 11.x core/modules/comment/tests/src/Kernel/Migrate/d6/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d6\MigrateCommentFieldInstanceTest::testMigration()
  6. 11.x core/modules/comment/tests/src/Kernel/Migrate/d7/MigrateCommentFieldInstanceTest.php \Drupal\Tests\comment\Kernel\Migrate\d7\MigrateCommentFieldInstanceTest::testMigration()

Test the migrated field instance values.

File

core/modules/comment/tests/src/Kernel/Migrate/d6/MigrateCommentFieldInstanceTest.php, line 74

Class

MigrateCommentFieldInstanceTest
Tests the migration of comment field instances from Drupal 6.

Namespace

Drupal\Tests\comment\Kernel\Migrate\d6

Code

public function testMigration() {
    $this->assertEntity('article', 'comment_node_article', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('company', 'comment_node_company', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('employee', 'comment_node_employee', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('event', 'comment_node_event', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('forum', 'comment_forum', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('page', 'comment_node_page', 0, 1, 50, 0, FALSE, 1);
    $this->assertEntity('sponsor', 'comment_node_sponsor', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('story', 'comment_node_story', 2, 0, 70, 1, FALSE, 0);
    $this->assertEntity('test_event', 'comment_node_test_event', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('test_page', 'comment_node_test_page', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('test_planet', 'comment_node_test_planet', 2, 1, 50, 0, FALSE, 1);
    $this->assertEntity('test_story', 'comment_node_test_story', 2, 1, 50, 0, FALSE, 1);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.