modify the cat test and fix npe