final unit tests and  integration tests; code refactored and reorganized for better future additions