public function GetTest::testTransformSourceString in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/migrate/tests/src/Unit/process/GetTest.php \Drupal\Tests\migrate\Unit\process\GetTest::testTransformSourceString()
Tests the Get plugin when source is a string.
File
- core/
modules/ migrate/ tests/ src/ Unit/ process/ GetTest.php, line 29 - Contains \Drupal\Tests\migrate\Unit\process\GetTest.
Class
- GetTest
- Tests the get process plugin.
Namespace
Drupal\Tests\migrate\Unit\processCode
public function testTransformSourceString() {
$this->row
->expects($this
->once())
->method('getSourceProperty')
->with('test')
->will($this
->returnValue('source_value'));
$this->plugin
->setSource('test');
$value = $this->plugin
->transform(NULL, $this->migrateExecutable, $this->row, 'destinationproperty');
$this
->assertSame($value, 'source_value');
}