MigrateAggregatorSettingsTest.php in Drupal 9
File
core/modules/aggregator/tests/src/Kernel/Migrate/d7/MigrateAggregatorSettingsTest.php
View source
<?php
namespace Drupal\Tests\aggregator\Kernel\Migrate\d7;
use Drupal\Tests\migrate_drupal\Kernel\d7\MigrateDrupal7TestBase;
class MigrateAggregatorSettingsTest extends MigrateDrupal7TestBase {
protected static $modules = [
'aggregator',
];
protected function setUp() : void {
parent::setUp();
$this
->installConfig(static::$modules);
$this
->executeMigration('d7_aggregator_settings');
}
public function testMigration() {
$config = \Drupal::config('aggregator.settings')
->get();
$this
->assertSame('aggregator', $config['fetcher']);
$this
->assertSame('aggregator', $config['parser']);
$this
->assertSame([
'aggregator',
], $config['processors']);
$this
->assertSame('<p> <div> <a>', $config['items']['allowed_html']);
$this
->assertSame(500, $config['items']['teaser_length']);
$this
->assertSame(86400, $config['items']['expire']);
$this
->assertSame(6, $config['source']['list_max']);
}
}