more cleanup and some test code removal