diff options
author | Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> | 2018-02-18 06:35:05 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2018-02-17 22:35:05 +0100 |
commit | 9b8a4484778fb55bcb2526992807a51270229b72 (patch) | |
tree | 7dad9ae3df644227645b7607a97776e8602a56dc /spec/rails_helper.rb | |
parent | a71af984011ff98df2fa1b7f6c983706a91d99bf (diff) |
Isolate each specs for cache store (#6450)
The cache store is explicitly used by some specs, but they were not isolated and therefore not reliable. This fixes the issue by clearing the cache after each specs.
Diffstat (limited to 'spec/rails_helper.rb')
-rw-r--r-- | spec/rails_helper.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 4f7399505..dc1f32e08 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -51,6 +51,8 @@ RSpec.configure do |config| end config.after :each do + Rails.cache.clear + keys = Redis.current.keys Redis.current.del(keys) if keys.any? end |