You are here

public function MigrateRangeFieldTest::testFieldInstanceMigration in Range 8

Same name in this branch
  1. 8 tests/src/Kernel/Migrate/d6/MigrateRangeFieldTest.php \Drupal\Tests\range\Kernel\Migrate\d6\MigrateRangeFieldTest::testFieldInstanceMigration()
  2. 8 tests/src/Kernel/Migrate/d7/MigrateRangeFieldTest.php \Drupal\Tests\range\Kernel\Migrate\d7\MigrateRangeFieldTest::testFieldInstanceMigration()

Tests migration of D6 range instances to field_config entities.

@dataProvider fieldInstanceMigrationDataProvider

File

tests/src/Kernel/Migrate/d6/MigrateRangeFieldTest.php, line 100

Class

MigrateRangeFieldTest
Tests Drupal 6 range fields migration.

Namespace

Drupal\Tests\range\Kernel\Migrate\d6

Code

public function testFieldInstanceMigration($id, $default_value, $settings) {

  /** @var \Drupal\Core\Field\FieldConfigInterface $field */
  $field = FieldConfig::load($id);
  $this
    ->assertSame($default_value, $field
    ->getDefaultValueLiteral());
  $this
    ->assertSame($settings, $field
    ->getSettings());
}