summaryrefslogtreecommitdiff
path: root/db/migrate/20210608103235_add_issue_index_to_test_report.rb
blob: 41f1970b2a9f2927247baf93c142e73c64b5ea0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

class AddIssueIndexToTestReport < ActiveRecord::Migration[6.1]
  include Gitlab::Database::MigrationHelpers

  disable_ddl_transaction!

  INDEX_NAME = 'index_requirements_management_test_reports_on_issue_id'

  def up
    add_concurrent_index :requirements_management_test_reports, :issue_id, name: INDEX_NAME
  end

  def down
    remove_concurrent_index_by_name :requirements_management_test_reports, INDEX_NAME
  end
end