From 9b8a4484778fb55bcb2526992807a51270229b72 Mon Sep 17 00:00:00 2001 From: Akihiko Odaki Date: Sun, 18 Feb 2018 06:35:05 +0900 Subject: 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. --- spec/rails_helper.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'spec/rails_helper.rb') 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 -- cgit