Commit baabba32 authored by Stan Hu's avatar Stan Hu

All specs using :elastic should clear Redis shared state

Let's stop the insanity of accepting dozens of merge requests to add
`:clean_gitlab_redis_shared_state` with specs that use `:elastic`. We
can do this dynamically in one place.

Closes https://gitlab.com/gitlab-org/gitlab/-/issues/330124
parent 941e229e
......@@ -56,6 +56,10 @@ module Elastic
end
RSpec.configure do |config|
config.define_derived_metadata do |meta|
meta[:clean_gitlab_redis_cache] = true if meta[:elastic] || meta[:elastic_delete_by_query]
end
config.around(:each, :elastic) do |example|
helper = Elastic::TestHelpers.new
helper.setup
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment