Adding code analysis and dependency injection