Refactoring to connection management and adding test taxonomy structure