Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
maxocub discovered in #2981393: Migrate D6 comment type language settings that the migration entity count in MigrateUpgrade6Test doesn't seem to be tested. He changed the value locally and the test still passed. See Comment #14.4.
This issue is to investigate that and make any necessary to changes to all the Drupal 6 and Drupal 7 tests affected.
Comment | File | Size | Author |
---|---|---|---|
#5 | interdiff-2-5.txt | 1.41 KB | quietone |
#5 | 3009137-5.patch | 3.36 KB | quietone |
#2 | 3009137-2.patch | 5.36 KB | quietone |
#2 | 3009137-2-fail.patch | 1.52 KB | quietone |
Comments
Comment #2
quietone CreditAttribution: quietone as a volunteer commentedThe test gets all the entities on the destination site and then checks that the count matches the count in the large array of expected counts. When there are more entity types in the expected array than on the actual site the count for those 'extra' entity types are simply ignored. When there are less entity types in the expected array than on the actual site the count for the 'missing' entity types defaults to zero and is tested. In both cases the list of expected entity types may not match what is actually tested. And I think they should.
The list of expected entity counts should be a accurate list of the entity types being tested.
To help make that happen I have added a test that compares the expected entity types with the actual entity types. And that test failed because contact_message was not in the expected list. Adding 'contact_message => 0' to the list and the test (MigrateUpgrade6Test) passed. The same line is added to the other tests but haven't run those tests locally.
The existing test is changed too, I removed the setting of the entity count to 0. That means that the expected count array now must list all the entities tested even if the count is 0.
Comment #4
quietone CreditAttribution: quietone as a volunteer commentedRemove changes to these to two files.
The fact that the failing test didn't have more failures has been bothering me. So, did some checking and these two tests aren't running the full migration (although with the entity count lists it looks like they do). They simply test that the migration does not run unless migrate_drupal_multilingual is enabled which, as I recall, was the intention at the time.
Tagging novice to remove the changes to MigrateUpgrade6NoMultilingualTest and MigrateUpgrade7NoMultilingualTest.
Comment #5
quietone CreditAttribution: quietone as a volunteer commentedRemoved items as per #4
Comment #6
maxocub CreditAttribution: maxocub commentedGreat, I'm glad you removed the default count of zero and the unused 'migration' count.
Comment #7
alexpottCommitted 9629b7a and pushed to 8.7.x. Thanks!
Testing against 8.6.x to see if we can backport.