public function PathTest::setUp in Feeds 8.3
Overrides FeedsKernelTestBase::setUp
File
- tests/
src/ Kernel/ Feeds/ Target/ PathTest.php, line 40
Class
- PathTest
- @coversDefaultClass \Drupal\feeds\Feeds\Target\Path @group feeds
Namespace
Drupal\Tests\feeds\Kernel\Feeds\TargetCode
public function setUp() {
parent::setUp();
// Install config for path module.
$this
->installEntitySchema('path_alias');
$this
->installEntitySchema('node');
// Create feed type.
$this->feedType = $this
->createFeedTypeForCsv([
'title' => 'title',
'alias' => 'alias',
], [
'processor_configuration' => [
'update_existing' => ProcessorInterface::UPDATE_EXISTING,
'authorize' => FALSE,
'values' => [
'type' => 'article',
],
],
'mappings' => [
[
'target' => 'title',
'map' => [
'value' => 'title',
],
'unique' => [
'value' => TRUE,
],
],
[
'target' => 'path',
'map' => [
'alias' => 'alias',
],
],
],
]);
$this->feedType
->save();
}