public function RowTest::testSetFrozenRow in Drupal 10
Same name and namespace in other branches
- 8 core/modules/migrate/tests/src/Unit/RowTest.php \Drupal\Tests\migrate\Unit\RowTest::testSetFrozenRow()
- 9 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 \Drupal\migrate\Row @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');
}