diff -u b/core/modules/migrate_drupal/tests/src/Traits/CreateTestContentEntitiesTrait.php b/core/modules/migrate_drupal/tests/src/Traits/CreateTestContentEntitiesTrait.php --- b/core/modules/migrate_drupal/tests/src/Traits/CreateTestContentEntitiesTrait.php +++ b/core/modules/migrate_drupal/tests/src/Traits/CreateTestContentEntitiesTrait.php @@ -57,59 +57,39 @@ } /** - * Create several pieces of generic content, except for feeds. + * Create several pieces of generic content. */ protected function createContent() { - $this->createBlockContent(); - $this->createNodeContent(); - $this->createFileContent(); - $this->createMenuLinkContent(); - $this->createTermContent(); - $this->createUserContent(); - } - - /** - * Create an aggregator feed and item. - */ - protected function createFeedContent() { - $feed = Feed::create([ - 'title' => 'feed', - 'url' => 'http://www.example.com', - ]); - $feed->save(); // Create an aggregator feed. + // Create an aggregator feed. $feed = Feed::create([ 'title' => 'feed', 'url' => 'http://www.example.com', ]); $feed->save(); + + // Create an aggregator feed item. $item = Item::create([ 'title' => 'feed item', 'fid' => $feed->id(), 'link' => 'http://www.example.com', ]); $item->save(); - } - /** - * Create block content. - */ - protected function createBlockContent() { + // Create a block content. $block = BlockContent::create([ 'info' => 'block', 'type' => 'block', ]); $block->save(); - } - /** - * Create a node and comment. - */ - protected function createNodeContent() { + // Create a node. $node = Node::create([ 'type' => 'page', 'title' => 'page', ]); $node->save(); + + // Create a comment. $comment = Comment::create([ 'comment_type' => 'comment', 'field_name' => 'comment', @@ -117,45 +97,29 @@ 'entity_id' => $node->id(), ]); $comment->save(); - } - /** - * Create a file. - */ - protected function createFileContent() { + // Create a file. $file = File::create([ 'uri' => 'public://example.txt', ]); $file->save(); - } - /** - * Create a menu link. - */ - protected function createMenuLinkContent() { + // Create a menu link. $menu_link = MenuLinkContent::create([ 'title' => 'menu link', 'link' => ['uri' => 'http://www.example.com'], 'menu_name' => 'tools', ]); $menu_link->save(); - } - /** - * Create a taxonomy term. - */ - protected function createTermContent() { + // Create a taxonomy term. $term = Term::create([ 'name' => 'term', 'vid' => 'term', ]); $term->save(); - } - /** - * Create a user. - */ - protected function createUserContent() { + // Create a user. $user = User::create([ 'uid' => 2, 'name' => 'user', @@ -166,2 +130,58 @@ + /** + * Create several pieces of generic content. + */ + protected function createContentPostUpgrade() { + // Create a block content. + $block = BlockContent::create([ + 'info' => 'Post upgrade block', + 'type' => 'block', + ]); + $block->save(); + + // Create a node. + $node = Node::create([ + 'type' => 'page', + 'title' => 'Post upgrade page', + ]); + $node->save(); + + // Create a comment. + $comment = Comment::create([ + 'comment_type' => 'comment', + 'field_name' => 'comment', + 'entity_type' => 'node', + 'entity_id' => $node->id(), + ]); + $comment->save(); + + // Create a file. + $file = File::create([ + 'uri' => 'public://post_upgrade_example.txt', + ]); + $file->save(); + + // Create a menu link. + $menu_link = MenuLinkContent::create([ + 'title' => 'post upgrade menu link', + 'link' => ['uri' => 'http://www.drupal.org'], + 'menu_name' => 'tools', + ]); + $menu_link->save(); + + // Create a taxonomy term. + $term = Term::create([ + 'name' => 'post upgrade term', + 'vid' => 'term', + ]); + $term->save(); + + // Create a user. + $user = User::create([ + 'uid' => 42, + 'name' => 'universe', + 'mail' => 'universe@example.com', + ]); + $user->save(); + } } diff -u b/core/modules/migrate_drupal_ui/tests/src/Functional/MigrateUpgradeTestBase.php b/core/modules/migrate_drupal_ui/tests/src/Functional/MigrateUpgradeTestBase.php --- b/core/modules/migrate_drupal_ui/tests/src/Functional/MigrateUpgradeTestBase.php +++ b/core/modules/migrate_drupal_ui/tests/src/Functional/MigrateUpgradeTestBase.php @@ -40,6 +40,7 @@ 'content_translation', 'migrate_drupal_ui', 'telephone', + 'aggregator', 'book', 'forum', 'statistics', @@ -201,6 +202,8 @@ \Drupal::service('module_installer')->install(['aggregator']); // Test incremental migration. + $this->createContentPostUpgrade(); + // Need to update available and missing path lists. $this->drupalGet('/upgrade'); $session->responseContains('An upgrade has already been performed on this site. To perform a new migration, create a clean and empty new install of Drupal 8. Rollbacks are not yet supported through the user interface.'); diff -u b/core/modules/migrate_drupal_ui/tests/src/Functional/d6/MigrateUpgrade6Test.php b/core/modules/migrate_drupal_ui/tests/src/Functional/d6/MigrateUpgrade6Test.php --- b/core/modules/migrate_drupal_ui/tests/src/Functional/d6/MigrateUpgrade6Test.php +++ b/core/modules/migrate_drupal_ui/tests/src/Functional/d6/MigrateUpgrade6Test.php @@ -83,16 +83,15 @@ */ protected function getEntityCountsIncremental() { $counts = $this->getEntityCounts(); - $counts['aggregator_feed'] = 1; - $counts['aggregator_item'] = 1; - $counts['base_field_override'] = 38; - $counts['entity_form_display'] = 29; + $counts['block_content'] = 3; + $counts['comment'] = 7; $counts['entity_view_display'] = 53; $counts['entity_view_mode'] = 14; - $counts['field_config'] = 84; - $counts['field_storage_config'] = 58; - $counts['node_type'] = 13; - $counts['rdf_mapping'] = 7; + $counts['file'] = 9; + $counts['menu_link_content'] = 6; + $counts['node'] = 18; + $counts['taxonomy_term'] = 9; + $counts['user'] = 8; $counts['view'] = 16; return $counts; } @@ -102,6 +101,7 @@ */ protected function getAvailablePaths() { return [ + 'aggregator', 'block', 'book', 'comment', @@ -146,7 +146,6 @@ */ protected function getMissingPaths() { return [ - 'aggregator', 'date_api', 'date_timezone', 'event', diff -u b/core/modules/migrate_drupal_ui/tests/src/Functional/d7/MigrateUpgrade7Test.php b/core/modules/migrate_drupal_ui/tests/src/Functional/d7/MigrateUpgrade7Test.php --- b/core/modules/migrate_drupal_ui/tests/src/Functional/d7/MigrateUpgrade7Test.php +++ b/core/modules/migrate_drupal_ui/tests/src/Functional/d7/MigrateUpgrade7Test.php @@ -39,6 +39,8 @@ */ protected function getEntityCounts() { return [ + 'aggregator_item' => 11, + 'aggregator_feed' => 1, 'block' => 25, 'block_content' => 1, 'block_content_type' => 1, @@ -86,16 +88,15 @@ */ protected function getEntityCountsIncremental() { $counts = $this->getEntityCounts(); - $counts['aggregator_feed'] = 1; - $counts['aggregator_item'] = 10; - $counts['base_field_override'] = 9; - $counts['entity_form_display'] = 17; + $counts['block_content'] = 2; + $counts['comment'] = 2; $counts['entity_view_display'] = 28; $counts['entity_view_mode'] = 14; - $counts['field_config'] = 61; - $counts['field_storage_config'] = 44; - $counts['rdf_mapping'] = 7; - $counts['taxonomy_term'] = 18; + $counts['file'] = 4; + $counts['menu_link_content'] = 9; + $counts['node'] = 6; + $counts['taxonomy_term'] = 19; + $counts['user'] = 5; $counts['view'] = 16; return $counts; } @@ -105,6 +106,7 @@ */ protected function getAvailablePaths() { return [ + 'aggregator', 'block', 'comment', 'contact', @@ -148,7 +150,6 @@ */ protected function getMissingPaths() { return [ - 'aggregator', 'blog', 'book', 'color',