diff options
Diffstat (limited to 'spec/migrations/20211214012507_backfill_incident_issue_escalation_statuses_spec.rb')
-rw-r--r-- | spec/migrations/20211214012507_backfill_incident_issue_escalation_statuses_spec.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/spec/migrations/20211214012507_backfill_incident_issue_escalation_statuses_spec.rb b/spec/migrations/20211214012507_backfill_incident_issue_escalation_statuses_spec.rb new file mode 100644 index 00000000000..0df52df43d8 --- /dev/null +++ b/spec/migrations/20211214012507_backfill_incident_issue_escalation_statuses_spec.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +require 'spec_helper' +require_migration! + +RSpec.describe BackfillIncidentIssueEscalationStatuses, feature_category: :incident_management do + let(:namespaces) { table(:namespaces) } + let(:projects) { table(:projects) } + let(:issues) { table(:issues) } + let(:namespace) { namespaces.create!(name: 'foo', path: 'foo') } + let(:project) { projects.create!(namespace_id: namespace.id) } + + # Backfill removed - see db/migrate/20220321234317_remove_all_issuable_escalation_statuses.rb. + it 'does nothing' do + issues.create!(project_id: project.id, issue_type: 1) + + expect { migrate! }.not_to change { BackgroundMigrationWorker.jobs.size } + end +end |