Fix caching tests