refactored integration tests and added todo for efficiency