Improve migration squash tooling
Right now, creating MRs to squash migrations (such as !167772 (merged)) starts with running the gitlab:db:squash rake task but then involves manual work to make the pipeline pass.
The work should be automated, so EP, the database team, or anyone else can create squash MRs more frequently and with next to no manual labor. Except for reviewing the MR.
This issue aims to improve the gitlab:db:squash rake task by automating these tasks:
-
Correctly generate db/init_structure.sql(i.e. withoutar_internal_metadataandschema_migrations) -
Delete classes associated with finalized BBMs (that have been finalized since one required stop) -
Update tff mapping tests -
Delete left-over specs -
Remove deleted migrations and specs from .rubocop_todo -
Update schemain specs
Edited by Heinrich Lee Yu