Minor changes and removal of old test code