Skip to content

Add cop to flag inconsistent gitlab_schema values

This MR is based on the pedropombeiro/494933/fix-tests-schema branch, please change to master before merging

Description of the proposal

This MR follows !167570 (merged) and adds a cop to flag inconsistent gitlab_schema values in calls to have_scheduled_batched_migration in migration specs. We had batched background migration specs that were testing rollbacks agains the gitlab_schema: :main (which is the default argument to have_scheduled_batched_migration), instead of using the same :gitlab_schema argument that is passed to the up migration spec. This results in a false positive for non-main schemas, since the main schema will never have the scheduled batched migration that we're creating in a different schema.

Having a cop will allow developers to notice early when a spec is inconsistent.

Closes #494933 (closed)

Check-list

  • Make sure this MR enables a static analysis check rule for new usage but ignores current offenses.
  • Mention this proposal in the relevant Slack channels (e.g. #development, #backend, #frontend).
  • If there is a choice to make between two potential styles, set up an emoji vote in the MR:
    • CHOICE_A: 🅰
    • CHOICE_B: 🅱
    • Vote for both choices, so they are visible to others.
  • The MR doesn't have significant objections, and is getting a majority of 👍 vs 👎 (remember that we don't need to reach a consensus).
  • (If applicable) One style is getting a majority of vote (compared to the other choice).
  • (If applicable) Update the MR with the chosen style.
  • Create a follow-up issue to fix the current offenses as a separate iteration: !167570 (merged)
  • Follow the review process as usual.
  • Once approved and merged by a maintainer, mention it again:
    • In the relevant Slack channels (e.g. #development, #backend, #frontend).
    • (Optional depending on the impact of the change) In the Engineering Week in Review.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

image

bundle exec rubocop --parallel spec/migrations/*_spec.rb
$ bundle exec rubocop --parallel spec/migrations/*_spec.rb
Inspecting 341 files
..............................C................................................C....C..CC.............CC..CC...C.........C.CCC...CCCC...C...CC..CCC.....CCCC...CCCCCC.CC.CCCCC.CCCCCCCCCCCC.....CC.CCCCC.CCCCCCC.CCCCCCCCCC.CCCC..C.CC..C.....C...CCC..C.CCC..C...CC.CCC..........C.CC.CC..CCCCCC.CCCC...C.CC.C.C.CCCCC...CC.........................

Offenses:

spec/migrations/20230815140656_queue_populate_denormalized_columns_for_sbom_occurrences_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20231218092401_queue_backfill_partition_id_ci_pipeline_chat_data_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240108082419_queue_backfill_partition_id_ci_pipeline_metadata_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240109090354_queue_backfill_partition_id_ci_pipeline_artifact_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240110090352_queue_backfill_partition_id_ci_pipeline_config_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240214203242_queue_backfill_sbom_occurrences_traversal_ids_and_archived_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240216020106_queue_backfill_cluster_agent_tokens_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240223130548_queue_update_sbom_components_name_based_on_pep503_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240226143323_queue_backup_and_remove_notes_with_null_noteable_type_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240306120522_queue_update_sbom_occurrences_component_name_based_on_pep503_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240410004337_queue_backfill_deployment_approvals_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240419035360_queue_backfill_workspace_variables_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240419035508_queue_backfill_work_item_parent_links_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240419035620_queue_backfill_wiki_repository_states_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240425205205_queue_remove_namespace_from_os_type_sbom_components_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240501044238_queue_backfill_approval_merge_request_rule_sources_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240501044351_queue_backfill_approval_merge_request_rules_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240501044505_queue_backfill_approval_project_rules_users_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240507152320_queue_migrate_os_sbom_occurrences_to_components_without_prefix_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240514140027_queue_backfill_audit_events_streaming_event_type_filters_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240514142206_queue_backfill_audit_events_streaming_headers_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240515155063_queue_backfill_design_management_designs_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240515155723_queue_backfill_design_management_repositories_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240516133621_queue_backfill_partition_id_ci_pipeline_message_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240521090846_queue_backfill_boards_epic_board_labels_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240521092459_queue_backfill_boards_epic_board_positions_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240521093524_queue_backfill_boards_epic_lists_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240521094917_queue_backfill_boards_epic_user_preferences_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240529112047_queue_backfill_wiki_page_slugs_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240529123638_queue_backfill_packages_build_infos_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240529184616_queue_backfill_agent_activity_events_agent_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240529185029_queue_backfill_dora_daily_metrics_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240530121656_queue_backfill_design_management_versions_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240530122159_queue_backfill_remote_development_agent_configs_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240531202753_queue_backfill_or_drop_ci_pipeline_on_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240603121642_queue_backfill_dast_pre_scan_verifications_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240604073805_queue_backfill_user_achievements_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240604074204_queue_backfill_ml_experiment_metadata_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240604145223_queue_backfill_dast_profiles_tags_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240604150020_queue_backfill_operations_strategies_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240604150537_queue_backfill_vulnerability_user_mentions_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605090456_queue_backfill_draft_notes_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605113250_queue_backfill_project_relation_exports_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605132810_queue_backfill_terraform_state_versions_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605192711_queue_backfill_dast_site_profile_secret_variables_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605193142_queue_backfill_merge_request_assignees_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240605193707_queue_backfill_vulnerability_state_transitions_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240607102721_queue_backfill_merge_request_assignment_events_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240607104316_queue_backfill_operations_feature_flags_issues_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240607104717_queue_backfill_vulnerability_merge_request_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240607105241_queue_backfill_packages_debian_group_distribution_keys_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240607105705_queue_backfill_dast_site_validations_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240610140905_queue_backfill_packages_debian_publications_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240611132547_queue_backfill_release_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240611142352_queue_backfill_status_check_responses_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240612071563_queue_backfill_epic_user_mentions_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240612072331_queue_backfill_merge_request_blocks_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240612073059_queue_backfill_operations_strategies_user_lists_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240612074837_queue_backfill_packages_debian_project_distribution_keys_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240612075305_queue_backfill_sbom_occurrences_vulnerabilities_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613064362_queue_backfill_vulnerability_issue_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613065420_queue_backfill_related_epic_links_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613071715_queue_backfill_packages_conan_metadata_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613072542_queue_backfill_merge_request_context_commits_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613073931_queue_backfill_issue_links_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613153409_queue_backfill_external_status_checks_protected_branches_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240613154933_queue_backfill_vulnerability_flags_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240618121521_queue_backfill_vulnerability_findings_remediations_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240618122511_queue_backfill_protected_tag_create_access_levels_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240618123929_queue_backfill_epic_issues_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240619142934_queue_backfill_vulnerability_finding_signatures_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240621114937_queue_backfill_merge_request_reviewers_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240621115731_queue_backfill_vulnerability_finding_evidences_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240621120705_queue_backfill_packages_maven_metadata_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240624135063_queue_backfill_vulnerability_external_issue_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240624142014_queue_backfill_merge_requests_closing_issues_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240624142361_queue_backfill_ml_model_metadata_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240626141557_queue_backfill_packages_dependency_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240626142206_queue_backfill_ml_candidate_metadata_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240627122810_queue_queue_backfill_autocancel_partition_id_on_ci_pipelines_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240627133840_queue_backfill_packages_debian_project_components_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240628133958_queue_backfill_packages_debian_project_architectures_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240701074852_queue_backfill_packages_debian_group_components_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240702072519_queue_backfill_packages_debian_group_architectures_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240708105034_queue_backfill_upstream_pipeline_partition_id_on_p_ci_builds_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240711035245_queue_backfill_root_namespace_cluster_agent_mappings_again_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240716133952_queue_backfill_evidences_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240716135032_queue_backfill_approval_group_rules_protected_branches_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240716135356_queue_backfill_approval_group_rules_users_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240717093514_requeue_backfill_partition_id_ci_daily_build_group_report_result_spec.rb:36:32: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
          expect(migration).to have_scheduled_batched_migration( ...
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240719090631_queue_backfill_approvals_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240722095915_queue_backfill_compliance_framework_security_policies_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240722095920_queue_backfill_compliance_framework_security_policies_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240725171401_queue_backfill_merge_request_user_mentions_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240729130352_queue_backfill_packages_package_files_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240729133635_queue_backfill_vulnerability_finding_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240730171961_queue_backfill_vulnerability_occurrence_identifiers_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240730172818_queue_backfill_vulnerability_occurrence_pipelines_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240731160144_queue_backfill_error_tracking_error_events_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240814075849_queue_copy_taggings_to_p_ci_build_tags_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240814104154_queue_backfill_protected_env_approval_rules_protected_env_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240814104159_queue_backfill_protected_env_approval_rules_protected_env_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240815083838_queue_backfill_protected_env_deploy_access_levels_protected_env_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240815083843_queue_backfill_protected_env_deploy_access_levels_protected_env_group_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240816130539_queue_backfill_security_orchestration_policy_rule_schedules_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240816130544_queue_backfill_security_orchestration_policy_rule_schedules_namespace_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240821075507_queue_backfill_ci_job_variables_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240826120429_queue_backfill_subscription_user_add_on_assignments_organization_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240827095907_queue_backfill_ci_build_needs_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240827165545_queue_backfill_project_id_to_security_scans_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240828074159_queue_backfill_p_ci_pipeline_variables_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240829160537_queue_backfill_p_ci_runner_machine_builds_project_id_spec.rb:13:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240829182925_queue_backfill_project_id_to_dependency_list_exports_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240830093237_queue_backfill_ml_candidate_metrics_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240906131415_queue_backfill_ml_candidate_params_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240910151508_queue_backfill_alert_management_alert_assignees_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240910154923_queue_delete_orphaned_build_records_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240912122440_queue_backfill_ci_job_artifact_states_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240915140444_queue_backfill_alert_management_alert_metric_images_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240916124325_queue_backfill_alert_management_alert_user_mentions_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240916130530_queue_backfill_incident_management_escalation_rules_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240916132826_queue_backfill_incident_management_oncall_rotations_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240918102413_queue_backfill_incident_management_timeline_event_tag_links_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240918111138_queue_backfill_milestone_releases_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240922141648_queue_backfill_incident_management_pending_alert_escalations_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spec/migrations/20240922144913_queue_backfill_ci_unit_test_failures_project_id_spec.rb:12:42: C: BackgroundMigration/ConsistentGitlabSchema: Ensure consistent :gitlab_schema argument values in have_scheduled_batched_migration calls.
        expect(batched_migration).not_to have_scheduled_batched_migration
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

341 files inspected, 126 offenses detected

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Roll back !167570 (merged).patch locally, and run bundle exec rubocop --parallel spec/migrations/*_spec.rb.

/cc @gitlab-org/maintainers/rails-backend

Edited by Pedro Pombeiro

Merge request reports

Loading