diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-07-21 06:10:13 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-07-21 06:10:13 +0300 |
commit | 3c0d15f2f194a4e08b2700b0a75c305d89dd7816 (patch) | |
tree | 9e987dcacb631d6159ba44909933d5f31103ed0e /spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb | |
parent | a558e386749c579a70cca6463926092926627388 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb')
-rw-r--r-- | spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb b/spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb new file mode 100644 index 00000000000..56bfa50abd0 --- /dev/null +++ b/spec/migrations/20230612232000_queue_backfill_dismissal_reason_in_vulnerability_reads_spec.rb @@ -0,0 +1,26 @@ +# frozen_string_literal: true + +require 'spec_helper' +require_migration! + +RSpec.describe QueueBackfillDismissalReasonInVulnerabilityReads, feature_category: :vulnerability_management do + let!(:batched_migration) { described_class::MIGRATION } + + it 'schedules a new batched migration' do + reversible_migration do |migration| + migration.before -> { + expect(batched_migration).not_to have_scheduled_batched_migration + } + + migration.after -> { + expect(batched_migration).to have_scheduled_batched_migration( + table_name: :vulnerability_reads, + column_name: :id, + interval: described_class::DELAY_INTERVAL, + batch_size: described_class::BATCH_SIZE, + sub_batch_size: described_class::SUB_BATCH_SIZE + ) + } + end + end +end |