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:
authorKamil Trzciński <ayufan@ayufan.eu>2019-06-07 13:01:52 +0300
committerKamil Trzciński <ayufan@ayufan.eu>2019-06-07 13:01:52 +0300
commit4b086b74509500998bdc28a82871aa2c9003a194 (patch)
tree24ae22da7dda0e328981c355417f691568f8f2b5 /spec/migrations
parentfd19f887dfeeeedb483c4a4fb32f9f768e89389c (diff)
parentb8704dce72fd8992b1f785c0ffa2f2c0eab81334 (diff)
Merge branch '62418-project-default-git-depth' into 'master'
Add project level git depth setting Closes #59688 See merge request gitlab-org/gitlab-ce!28919
Diffstat (limited to 'spec/migrations')
-rw-r--r--spec/migrations/remove_orphaned_label_links_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/migrations/remove_orphaned_label_links_spec.rb b/spec/migrations/remove_orphaned_label_links_spec.rb
index 13b8919343e..e8c44c141c3 100644
--- a/spec/migrations/remove_orphaned_label_links_spec.rb
+++ b/spec/migrations/remove_orphaned_label_links_spec.rb
@@ -10,6 +10,12 @@ describe RemoveOrphanedLabelLinks, :migration do
let(:project) { create(:project) } # rubocop:disable RSpec/FactoriesInMigrationSpecs
let(:label) { create_label }
+ before do
+ # This migration was created before we introduced ProjectCiCdSetting#default_git_depth
+ allow_any_instance_of(ProjectCiCdSetting).to receive(:default_git_depth).and_return(nil)
+ allow_any_instance_of(ProjectCiCdSetting).to receive(:default_git_depth=).and_return(0)
+ end
+
context 'add foreign key on label_id' do
let!(:label_link_with_label) { create_label_link(label_id: label.id) }
let!(:label_link_without_label) { create_label_link(label_id: nil) }