Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/migrations/20230721095222_delete_orphans_scan_finding_license_scanning_approval_rules2_spec.rb')
-rw-r--r--spec/migrations/20230721095222_delete_orphans_scan_finding_license_scanning_approval_rules2_spec.rb22
1 files changed, 22 insertions, 0 deletions
diff --git a/spec/migrations/20230721095222_delete_orphans_scan_finding_license_scanning_approval_rules2_spec.rb b/spec/migrations/20230721095222_delete_orphans_scan_finding_license_scanning_approval_rules2_spec.rb
new file mode 100644
index 00000000000..2baf0975c5c
--- /dev/null
+++ b/spec/migrations/20230721095222_delete_orphans_scan_finding_license_scanning_approval_rules2_spec.rb
@@ -0,0 +1,22 @@
+# frozen_string_literal: true
+
+require 'spec_helper'
+require_migration!
+
+RSpec.describe DeleteOrphansScanFindingLicenseScanningApprovalRules2, feature_category: :security_policy_management do
+ describe '#up' do
+ it 'schedules background migration for both levels of approval rules' do
+ migrate!
+
+ expect(described_class::MERGE_REQUEST_MIGRATION).to have_scheduled_batched_migration(
+ table_name: :approval_merge_request_rules,
+ column_name: :id,
+ interval: described_class::INTERVAL)
+
+ expect(described_class::PROJECT_MIGRATION).to have_scheduled_batched_migration(
+ table_name: :approval_project_rules,
+ column_name: :id,
+ interval: described_class::INTERVAL)
+ end
+ end
+end