cache.rb 497 B

1234567891011121314151617
  1. RSpec.configure do |config|
  2. # Cache setup must be the first before hook
  3. # Otherwise authenticated_as hook fails with random errors
  4. config.prepend_before(:each) do
  5. # clear the cache otherwise it won't
  6. # be able to recognize the rollbacks
  7. # done by RSpec
  8. Cache.clear
  9. # clear Setting cache to prevent leaking
  10. # of Setting changes from previous test examples
  11. Setting.reload
  12. # reset bulk import to prevent wrong base setting
  13. BulkImportInfo.disable
  14. end
  15. end