function RowTest::testSetFrozenRow
Same name and namespace in other branches
- 8.9.x core/modules/migrate/tests/src/Unit/RowTest.php \Drupal\Tests\migrate\Unit\RowTest::testSetFrozenRow()
- 10 core/modules/migrate/tests/src/Unit/RowTest.php \Drupal\Tests\migrate\Unit\RowTest::testSetFrozenRow()
- 11.x core/modules/migrate/tests/src/Unit/RowTest.php \Drupal\Tests\migrate\Unit\RowTest::testSetFrozenRow()
Tests setting on a frozen row.
File
-
core/
modules/ migrate/ tests/ src/ Unit/ RowTest.php, line 140
Class
- RowTest
- @coversDefaultClass <a href="/api/drupal/core%21modules%21migrate%21src%21Row.php/class/Row/9" title="Stores a row." class="local">\Drupal\migrate\Row</a> @group migrate
Namespace
Drupal\Tests\migrate\UnitCode
public function testSetFrozenRow() {
$row = new Row($this->testValues, $this->testSourceIds);
$row->freezeSource();
$this->expectException(\Exception::class);
$this->expectExceptionMessage("The source is frozen and can't be changed any more");
$row->setSourceProperty('title', 'new title');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.