summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzegorz@gitlab.com>2019-04-02 13:20:27 +0000
committerGrzegorz Bizon <grzegorz@gitlab.com>2019-04-02 13:20:27 +0000
commit4ca1c51e25fb108d4fa1d40ec7930f6bd0590908 (patch)
tree13efbc7330efcd8760ff9f6bfbdc0c1dd44ca155 /spec
parent4b9dbec33ce446362d617f481b35628890763bd7 (diff)
parent35b9274f12f29524855237bfdcd864497d62de95 (diff)
downloadgitlab-ce-4ca1c51e25fb108d4fa1d40ec7930f6bd0590908.tar.gz
Merge branch 'jv-gitaly-unlink-repository' into 'master'
Stop calling UnlinkRepositoryFromObjectPool RPC Closes #59777 See merge request gitlab-org/gitlab-ce!26821
Diffstat (limited to 'spec')
-rw-r--r--spec/models/pool_repository_spec.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/models/pool_repository_spec.rb b/spec/models/pool_repository_spec.rb
index 112d4ab56fc..e5a3a3ad66e 100644
--- a/spec/models/pool_repository_spec.rb
+++ b/spec/models/pool_repository_spec.rb
@@ -24,14 +24,14 @@ describe PoolRepository do
end
end
- describe '#unlink_repository' do
+ describe '#mark_obsolete_if_last' do
let(:pool) { create(:pool_repository, :ready) }
context 'when the last member leaves' do
it 'schedules pool removal' do
expect(::ObjectPool::DestroyWorker).to receive(:perform_async).with(pool.id).and_call_original
- pool.unlink_repository(pool.source_project.repository)
+ pool.mark_obsolete_if_last(pool.source_project.repository)
end
end
@@ -40,7 +40,7 @@ describe PoolRepository do
create(:project, :repository, pool_repository: pool)
expect(::ObjectPool::DestroyWorker).not_to receive(:perform_async).with(pool.id)
- pool.unlink_repository(pool.source_project.repository)
+ pool.mark_obsolete_if_last(pool.source_project.repository)
end
end
end