remove unneeded code in tests.