function MigrateViewModesTest::testMigration

Same name in other branches
  1. 8.9.x core/modules/field/tests/src/Kernel/Migrate/d7/MigrateViewModesTest.php \Drupal\Tests\field\Kernel\Migrate\d7\MigrateViewModesTest::testMigration()
  2. 10 core/modules/field/tests/src/Kernel/Migrate/d7/MigrateViewModesTest.php \Drupal\Tests\field\Kernel\Migrate\d7\MigrateViewModesTest::testMigration()
  3. 11.x core/modules/field/tests/src/Kernel/Migrate/d7/MigrateViewModesTest.php \Drupal\Tests\field\Kernel\Migrate\d7\MigrateViewModesTest::testMigration()

Tests migration of D7 view mode variables to D8 config entities.

1 call to MigrateViewModesTest::testMigration()
RollbackViewModesTest::testMigration in core/modules/field/tests/src/Kernel/Migrate/d7/RollbackViewModesTest.php
Tests migrating D7 view modes, then rolling back.
1 method overrides MigrateViewModesTest::testMigration()
RollbackViewModesTest::testMigration in core/modules/field/tests/src/Kernel/Migrate/d7/RollbackViewModesTest.php
Tests migrating D7 view modes, then rolling back.

File

core/modules/field/tests/src/Kernel/Migrate/d7/MigrateViewModesTest.php, line 51

Class

MigrateViewModesTest
Tests migration of D7 view modes.

Namespace

Drupal\Tests\field\Kernel\Migrate\d7

Code

public function testMigration() {
    $this->assertEntity('comment.full', 'Full', 'comment');
    $this->assertEntity('node.teaser', 'Teaser', 'node');
    $this->assertEntity('node.full', 'Full', 'node');
    $this->assertEntity('node.custom', 'custom', 'node');
    $this->assertEntity('user.full', 'Full', 'user');
}

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