You are here

public function ExtractTest::testExtract in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/migrate/tests/src/Unit/process/ExtractTest.php \Drupal\Tests\migrate\Unit\process\ExtractTest::testExtract()
  2. 10 core/modules/migrate/tests/src/Unit/process/ExtractTest.php \Drupal\Tests\migrate\Unit\process\ExtractTest::testExtract()

Tests successful extraction.

File

core/modules/migrate/tests/src/Unit/process/ExtractTest.php, line 26

Class

ExtractTest
@coversDefaultClass \Drupal\migrate\Plugin\migrate\process\Extract @group migrate

Namespace

Drupal\Tests\migrate\Unit\process

Code

public function testExtract() {
  $value = $this->plugin
    ->transform([
    'foo' => 'bar',
  ], $this->migrateExecutable, $this->row, 'destination_property');
  $this
    ->assertSame('bar', $value);
}