public void TryResolvingViaChildKernelShouldNotThrowException() { using (var childKernel = new DefaultKernel()) { Kernel.Register(Component.For<BookStore>()); Kernel.AddChildKernel(childKernel); var handler = childKernel.GetHandler(typeof(BookStore)); // Assert setup invariant Assert.IsInstanceOf<ParentHandlerWrapper>(handler); Assert.DoesNotThrow(() => handler.TryResolve(CreationContext.CreateEmpty())); } }