mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-30 21:27:17 +00:00
Clears cache around examples
for specs testing cache
This commit is contained in:
@@ -19,6 +19,11 @@ describe "Darkswarm data caching", caching: true do
|
||||
}
|
||||
let(:exchange) { order_cycle.exchanges.outgoing.where(receiver_id: distributor.id).first }
|
||||
|
||||
around do |example|
|
||||
Rails.cache.clear
|
||||
example.run
|
||||
end
|
||||
|
||||
before do
|
||||
exchange.variants << product.variants.first
|
||||
end
|
||||
|
||||
@@ -13,6 +13,11 @@ describe "Shops caching", caching: true do
|
||||
create(:open_order_cycle, distributors: [distributor], coordinator: distributor)
|
||||
}
|
||||
|
||||
around do |example|
|
||||
Rails.cache.clear
|
||||
example.run
|
||||
end
|
||||
|
||||
describe "caching enterprises AMS data" do
|
||||
it "caches data for all enterprises, with the provided options" do
|
||||
visit shops_path
|
||||
|
||||
Reference in New Issue
Block a user