Cleaned up classes and updated unit test