public void TestInitialize() { this.target = new Container(); this.target.AddRegistrationEntry(typeof(TestClassA), new RegistrationEntry(typeof(TestClassA), new ContainerLifetime())); this.target.AddRegistrationEntry(typeof(TestClassB), new RegistrationEntry(typeof(TestClassB))); this.target.AddRegistrationEntry(typeof(TestClassC), new RegistrationEntry(typeof(TestClassC))); this.target.AddRegistrationEntry(typeof(TestClassD), new RegistrationEntry(typeof(TestClassD), new PerResolveLifetime())); this.target.AddRegistrationEntry(typeof(ITestClassC), new RegistrationEntry(typeof(TestClassC))); }
public TestClassA(Container container) { this.Container = container; }
public Container CreateChildContainer() { Container childContainer = new Container(); childContainer.repository = this.repository; return childContainer; }