Make ApplicationContext more robust

By including members with non-public visibility
This commit is contained in:
Mike Bierlee 2016-02-10 00:36:44 +01:00
parent 13921a128e
commit f2ff12dc58

View file

@ -25,7 +25,7 @@ version(unittest) {
class AutowiredTestContext : ApplicationContext { class AutowiredTestContext : ApplicationContext {
@Autowire @Autowire
public UnrelatedClass unrelatedClass; private UnrelatedClass unrelatedClass;
@Component @Component
public ClassWrapper wrapper() { public ClassWrapper wrapper() {
@ -36,10 +36,10 @@ version(unittest) {
class ComplexAutowiredTestContext : ApplicationContext { class ComplexAutowiredTestContext : ApplicationContext {
@Autowire @Autowire
public UnrelatedClass unrelatedClass; private UnrelatedClass unrelatedClass;
@Autowire @Autowire
public ClassWrapper classWrapper; protected ClassWrapper classWrapper;
public override void registerDependencies(shared(DependencyContainer) container) { public override void registerDependencies(shared(DependencyContainer) container) {
container.register!UnrelatedClass; container.register!UnrelatedClass;