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:
Diffstat (limited to 'spec/lib/gitlab/repository_hash_cache_spec.rb')
-rw-r--r--spec/lib/gitlab/repository_hash_cache_spec.rb31
1 files changed, 8 insertions, 23 deletions
diff --git a/spec/lib/gitlab/repository_hash_cache_spec.rb b/spec/lib/gitlab/repository_hash_cache_spec.rb
index d41bf45f72e..6b52c315a70 100644
--- a/spec/lib/gitlab/repository_hash_cache_spec.rb
+++ b/spec/lib/gitlab/repository_hash_cache_spec.rb
@@ -69,35 +69,20 @@ RSpec.describe Gitlab::RepositoryHashCache, :clean_gitlab_redis_cache do
end
end
- shared_examples "key?" do
- describe "#key?" do
- subject { cache.key?(:example, "test") }
+ describe "#key?" do
+ subject { cache.key?(:example, "test") }
- context "key exists" do
- before do
- cache.write(:example, test_hash)
- end
-
- it { is_expected.to be(true) }
+ context "key exists" do
+ before do
+ cache.write(:example, test_hash)
end
- context "key doesn't exist" do
- it { is_expected.to be(false) }
- end
+ it { is_expected.to be(true) }
end
- end
-
- context "when both multistore FF is enabled" do
- it_behaves_like "key?"
- end
- context "when both multistore FF is disabled" do
- before do
- stub_feature_flags(use_primary_and_secondary_stores_for_repository_cache: false)
- stub_feature_flags(use_primary_store_as_default_for_repository_cache: false)
+ context "key doesn't exist" do
+ it { is_expected.to be(false) }
end
-
- it_behaves_like "key?"
end
describe "#read_members" do