function MachineNameTest::testInvalidConfiguration
Tests that the replacement regular expression is a string.
File
- 
              core/modules/ migrate/ tests/ src/ Unit/ process/ MachineNameTest.php, line 98 
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);
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
