Update hook/error/cache . Added tests