public function MachineNameTest::testInvalidConfiguration in Drupal 9
Tests that the replacement regular expression is a string.
File
- core/
modules/ migrate/ tests/ src/ Unit/ process/ MachineNameTest.php, line 96
Class
- MachineNameTest
- Tests the machine name process plugin.
Namespace
Drupal\Tests\migrate\Unit\processCode
public function testInvalidConfiguration() : void {
$configuration['replace_pattern'] = 1;
$this
->expectException(MigrateException::class);
$this
->expectExceptionMessage('The replace pattern should be a string');
new MachineName($configuration, 'machine_name', [], $this->transliteration);
}