Re:One Year After Switching from Java to Go: Our Experiences
by roncesvalles on Wednesday February 19, 2025 @03:04AM
(#43099791)
Such an instance would just be a variable somewhere that would be initialized in some init() call when the program starts. Every user of that instance will use it directly (as opposed to storing a reference to it locally DI style).
How would you construct an instance in a test that needs mock implementations?