Added unit tests and cleaned up some code The setup for acceptance tests now cleans up the environment