public void Conainter_RegisterInstance_RegistrationSuccesfull() { string elem = "sapte"; _container.Register(elem); var result = _container.Resolve <string>(); Assert.AreSame(elem, result); }
public void Container_KnownCtorWithConcreteParam_ResolvesSuccesfully() { ITestObj expectedTestObj = new TestObj { Item = ExpectedItem }; _container.Register <TestObjComplex>(new KnownCtor(expectedTestObj)); var result = _container.Resolve <TestObjComplex>(); Assert.NotNull(result); Assert.AreEqual(expectedTestObj, result.Obj1); }