You are here

public function LinkCckTest::testAlterFieldInstanceMigration in Drupal 8

@covers ::alterFieldInstanceMigration

1 call to LinkCckTest::testAlterFieldInstanceMigration()
LinkCckDeprecationTest::testAlterFieldInstanceMigration in core/modules/link/tests/src/Kernel/Plugin/migrate/cckfield/d7/LinkCckDeprecationTest.php
@expectedDeprecation Deprecated in Drupal 8.6.0, to be removed before Drupal 9.0.0. Use alterFieldInstanceMigration() instead. See https://www.drupal.org/node/2944598.
1 method overrides LinkCckTest::testAlterFieldInstanceMigration()
LinkCckDeprecationTest::testAlterFieldInstanceMigration in core/modules/link/tests/src/Kernel/Plugin/migrate/cckfield/d7/LinkCckDeprecationTest.php
@expectedDeprecation Deprecated in Drupal 8.6.0, to be removed before Drupal 9.0.0. Use alterFieldInstanceMigration() instead. See https://www.drupal.org/node/2944598.

File

core/modules/link/tests/src/Kernel/Plugin/migrate/cckfield/d7/LinkCckTest.php, line 57

Class

LinkCckTest
@coversDefaultClass \Drupal\link\Plugin\migrate\cckfield\d7\LinkField @group link @group legacy

Namespace

Drupal\Tests\link\Kernel\Plugin\migrate\cckfield\d7

Code

public function testAlterFieldInstanceMigration($method = 'alterFieldInstanceMigration') {
  $this->plugin
    ->{$method}($this->migration);
  $expected = [
    'plugin' => 'static_map',
    'source' => 'settings/title',
    'bypass' => TRUE,
    'map' => [
      'disabled' => DRUPAL_DISABLED,
      'optional' => DRUPAL_OPTIONAL,
      'required' => DRUPAL_REQUIRED,
    ],
  ];
  $this
    ->assertSame($expected, $this->migration
    ->getProcess());
}