Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / book / tests / src / Kernel / Migrate / d6 / MigrateBookConfigsTest.php
index becf87d3c9e3ad3e52b279de74741da70938fbd5..7498638455a583fbf5a63173a739cdd8d34ba6bf 100644 (file)
@@ -20,17 +20,29 @@ class MigrateBookConfigsTest extends MigrateDrupal6TestBase {
   public static $modules = ['book'];
 
   /**
-   * {@inheritdoc}
+   * Data provider for testBookSettings().
+   *
+   * @return array
+   *   The data for each test scenario.
    */
-  protected function setUp() {
-    parent::setUp();
-    $this->executeMigration('d6_book_settings');
+  public function providerBookSettings() {
+    return [
+      // d6_book_settings was renamed to book_settings, but use the old alias to
+      // prove that it works.
+      // @see book_migration_plugins_alter()
+      ['d6_book_settings'],
+      ['book_settings'],
+    ];
   }
 
   /**
    * Tests migration of book variables to book.settings.yml.
+   *
+   * @dataProvider providerBookSettings
    */
-  public function testBookSettings() {
+  public function testBookSettings($migration_id) {
+    $this->executeMigration($migration_id);
+
     $config = $this->config('book.settings');
     $this->assertIdentical('book', $config->get('child_type'));
     $this->assertSame('book pages', $config->get('block.navigation.mode'));