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/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 55ee846090f..688deb78020 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -332,6 +332,13 @@ RSpec.configure do |config|
Gitlab::WithRequestStore.with_request_store { example.run }
end
+ config.before(:example, :request_store) do
+ # Clear request store before actually starting the spec (the
+ # `around` above will have the request store enabled for all
+ # `before` blocks)
+ RequestStore.clear!
+ end
+
config.around do |example|
# Wrap each example in it's own context to make sure the contexts don't
# leak