Added cache builder and test cases.