Fix MigrateTestBase::executeMigrations() to execute migrations in dependency order

Created on 21 November 2018, about 6 years ago
Updated 27 November 2023, about 1 year ago

Problem/Motivation

The documentation for this function is:

 /**
   * Executes a set of migrations in dependency order.
   *
   * @param string[] $ids
   *   Array of migration IDs, in any order.
   */

however the function executes the migrations in the order they are passed, not in dependency order

Proposed resolution

Refactor the helper function to execute in dependency order. This shouldn't break existing usages, since executing migrations out of order would cause the tests to fail. This will allow future use of this method to work properly

Remaining tasks

Commit

User interface changes

none

API changes

none, as tests are not part of the API. This method is likely used in contrib though, and it would begin working as advertised.

Data model changes

none

πŸ› Bug report
Status

Fixed

Version

10.1 ✨

Component
MigrationΒ  β†’

Last updated about 13 hours ago

Created by

πŸ‡ΊπŸ‡ΈUnited States mikelutz Michigan, USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024