summaryrefslogtreecommitdiff
path: root/spec/models/repository_spec.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-08-11 18:10:06 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-08-11 18:10:06 +0000
commit7a1895c74ad57da757c02b2675147a5a5e2cfe6d (patch)
tree7204fd4cdecbf1166f1aebca080994fcb7f290cd /spec/models/repository_spec.rb
parent9dde2726710184f066387d044fce4ae2b3684210 (diff)
downloadgitlab-ce-7a1895c74ad57da757c02b2675147a5a5e2cfe6d.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/models/repository_spec.rb')
-rw-r--r--spec/models/repository_spec.rb12
1 files changed, 8 insertions, 4 deletions
diff --git a/spec/models/repository_spec.rb b/spec/models/repository_spec.rb
index 07b32aa69ef..48dee1e6481 100644
--- a/spec/models/repository_spec.rb
+++ b/spec/models/repository_spec.rb
@@ -587,15 +587,19 @@ RSpec.describe Repository do
end
it "is expired when the branches caches are expired" do
- expect(cache).to receive(:delete).with(:merged_branch_names).at_least(:once)
+ expect(cache).to receive(:delete) do |*args|
+ expect(args).to include(:merged_branch_names)
+ end
- repository.send(:expire_branches_cache)
+ repository.expire_branches_cache
end
it "is expired when the repository caches are expired" do
- expect(cache).to receive(:delete).with(:merged_branch_names).at_least(:once)
+ expect(cache).to receive(:delete) do |*args|
+ expect(args).to include(:merged_branch_names)
+ end
- repository.send(:expire_all_method_caches)
+ repository.expire_all_method_caches
end
end