public void CreateFunctionWithParamsCreatesCorrectObject() { int integerParam = 7; string textParam = "TEST_STRING"; ITestClassWithParams etalon_object = new TestClassWithParams(integerParam, textParam); ITestClassWithParams created_object = classFactory.Create <ITestClassWithParams>(integerParam, textParam); Assert.ReferenceEquals(etalon_object, created_object); }
public void CreateFunctionWithParams_Object_PropertyDeepCheck() { int integerParam = 7; string textParam = "TEST_STRING"; ITestClassWithParams etalon_object = new TestClassWithParams(integerParam, textParam); ITestClassWithParams created_object = classFactory.Create <ITestClassWithParams>(integerParam, textParam); Assert.AreEqual(etalon_object.integer, created_object.integer); Assert.AreEqual(etalon_object.text, created_object.text); }