public void InjectionFailDependencyNotFound() { SimpleDependencyInjector di = new SimpleDependencyInjector(); di.Register(typeof(MyClass), typeof(IClass)); di.Register(typeof(MyClass3), typeof(IClass3)); TestClass testClass = di.CallCtor(typeof(TestClass)) as TestClass; }
public void InjectionFaiedInstanseNotFounded() { SimpleDependencyInjector di = new SimpleDependencyInjector(); di.Register(typeof(MyClass), typeof(IClass)); TestClass testClass = di.CallCtor(typeof(TestClass)) as TestClass; Assert.AreEqual(true, testClass.IsGood); }