You are here

protected function UrlEncodeTest::doTransform in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate/tests/src/Unit/process/UrlEncodeTest.php \Drupal\Tests\migrate\Unit\process\UrlEncodeTest::doTransform()

Perform the urlencode process plugin over the given value.

Parameters

string $value: URL to be encoded.

Return value

string Encoded URL.

1 call to UrlEncodeTest::doTransform()
UrlEncodeTest::testUrls in core/modules/migrate/tests/src/Unit/process/UrlEncodeTest.php
Cover various encoding scenarios. @dataProvider urlDataProvider

File

core/modules/migrate/tests/src/Unit/process/UrlEncodeTest.php, line 57

Class

UrlEncodeTest
@coversDefaultClass \Drupal\migrate\Plugin\migrate\process\UrlEncode @group file

Namespace

Drupal\Tests\migrate\Unit\process

Code

protected function doTransform($value) {
  $executable = new MigrateExecutable($this
    ->getMigration());
  $row = new Row();
  return (new UrlEncode([], 'urlencode', []))
    ->transform($value, $executable, $row, 'foobaz');
}