LightInject will look for an ICompositionRoot implementation in the same assembly as the requested service. [...] If such an implementation does not exists or that we for some other reason need to configure the container, we can do this by simply implementing a static method in the test class [...]
I seldom have my composition root in the same assembly as the service. I also wouldn't like to declare the Configure-method in every testclass. Wouldn't a ICompositionRoot in the test assembly be a better way of configure the container?
I seldom have my composition root in the same assembly as the service. I also wouldn't like to declare the
Configure
-method in every testclass. Wouldn't aICompositionRoot
in the test assembly be a better way of configure the container?