Remove useless code in test