public function MigrateMessageTest::setUp in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/migrate/src/Tests/MigrateMessageTest.php \Drupal\migrate\Tests\MigrateMessageTest::setUp()
Performs setup tasks before each individual test method is run.
Overrides KernelTestBase::setUp
File
- core/
modules/ migrate/ src/ Tests/ MigrateMessageTest.php, line 49 - Contains \Drupal\migrate\Tests\MigrateMessageTest.
Class
- MigrateMessageTest
- Test whether idmap messages are sent to the message interface when requested.
Namespace
Drupal\migrate\TestsCode
public function setUp() {
parent::setUp();
$this
->installConfig([
'system',
]);
// A simple migration, which will generate a message to the id map because
// the concat plugin throws an exception if its source is not an array.
$config = [
'id' => 'sample_data',
'migration_tags' => [
'Message test',
],
'source' => [
'plugin' => 'embedded_data',
'data_rows' => [
[
'name' => 'source_message',
'value' => 'a message',
],
],
'ids' => [
'name' => [
'type' => 'string',
],
],
],
'process' => [
'message' => [
'plugin' => 'concat',
'source' => 'value',
],
],
'destination' => [
'plugin' => 'config',
'config_name' => 'system.maintenance',
],
];
$this->migration = Migration::create($config);
}