test cases for cache