Comment on Dependency Injection with GoparentComments−nostrademons12yThey're trying to pass the objects created at startup into other objects, so that dependencies are explicit and can be mocked out in unit tests. You can't do this with init(), which always takes no arguments and returns no values.
Comments
They're trying to pass the objects created at startup into other objects, so that dependencies are explicit and can be mocked out in unit tests. You can't do this with init(), which always takes no arguments and returns no values.