FieldLink example

/** * @group Link */
class FieldLinkTest extends UnitTestCase {

  /** * Tests the URL transformations in the FieldLink process plugin. * * @dataProvider canonicalizeUriDataProvider */
  public function testCanonicalizeUri($url$expected$configuration = []) {
    $link_plugin = new FieldLink($configuration, '', []$this->createMock(MigrationInterface::class));
    $transformed = $link_plugin->transform([
      'url' => $url,
      'title' => '',
      'attributes' => serialize([]),
    ]$this->createMock(MigrateExecutableInterface::class)$this->getMockBuilder(Row::class)->disableOriginalConstructor()->getMock(), NULL);
    $this->assertEquals($expected$transformed['uri']);
  }

  /** * Data provider for testCanonicalizeUri. */
  
Home | Imprint | This part of the site doesn't use cookies.