Test for cache invalidation