Commit 2fbb1a03 authored by webchick's avatar webchick

Issue #2353777 by phenaproxima, joshtaylor, chx: Variable to config: tracker.settings [d7]

parent bbde5c05
......@@ -355,6 +355,9 @@ public function load() {
))->values(array(
'name' => 'theme_default',
'value' => 's:6:"bartik";',
))->values(array(
'name' => 'tracker_batch_size',
'value' => 'i:999;',
))->values(array(
'name' => 'user_admin_role',
'value' => 's:1:"3";',
......@@ -467,4 +470,4 @@ public function load() {
}
}
#b936ad0308ecdde6a8fe71fd158c6719
#e0f7be890a222531c707941d0fedf479
id: d7_tracker_settings
label: Drupal 7 tracker settings
migration_tags:
- Drupal 7
source:
plugin: variable
variables:
- tracker_batch_size
process:
cron_index_limit: tracker_batch_size
destination:
plugin: config
config_name: tracker.settings
<?php
/**
* @file
* Contains \Drupal\tracker\Tests\Migrate\d7\MigrateTrackerSettingsTest.
*/
namespace Drupal\tracker\Tests\Migrate\d7;
use Drupal\migrate_drupal\Tests\d7\MigrateDrupal7TestBase;
/**
* Tests migration of Tracker settings to configuration.
*
* @group tracker
*/
class MigrateTrackerSettingsTest extends MigrateDrupal7TestBase {
public static $modules = ['tracker'];
/**
* {@inheritdoc}
*/
protected function setUp() {
parent::setUp();
$this->installConfig(['tracker']);
$this->loadDumps(['Variable.php']);
$this->executeMigration('d7_tracker_settings');
}
/**
* Tests migration of tracker's variables to configuration.
*/
public function testMigration() {
$this->assertIdentical(999, \Drupal::config('tracker.settings')->get('cron_index_limit'));
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment