Finished most of the tests and got rid of old code