MenuTest.php in Zircon Profile 8
File
core/modules/system/tests/src/Unit/Plugin/migrate/source/MenuTest.php
View source
<?php
namespace Drupal\Tests\system\Unit\Plugin\migrate\source;
use Drupal\Tests\migrate\Unit\MigrateSqlSourceTestCase;
class MenuTest extends MigrateSqlSourceTestCase {
const PLUGIN_CLASS = 'Drupal\\system\\Plugin\\migrate\\source\\Menu';
protected $migrationConfiguration = array(
'id' => 'test',
'source' => array(
'plugin' => 'menu',
),
);
protected $expectedResults = array(
array(
'menu_name' => 'menu-name-1',
'title' => 'menu custom value 1',
'description' => 'menu custom description value 1',
),
array(
'menu_name' => 'menu-name-2',
'title' => 'menu custom value 2',
'description' => 'menu custom description value 2',
),
);
protected function setUp() {
$this->databaseContents['menu_custom'] = $this->expectedResults;
parent::setUp();
}
}