Updating of cache, with test