public void MembersIgnoredViaModifier() { var modelC = new TestModels.ModelC(); modelC.IgnoredMember = "test is a value"; var clonedModelC = SerializationTestHelper.SerializeAndDeserialize(modelC, SerializationFactory.GetXmlSerializer()); Assert.AreEqual(null, clonedModelC.IgnoredMember); }
public void ComplexInheritanceWorksWithBinary() { var modelC = new TestModels.ModelC(); Assert.IsNull(modelC.ModelAProperty); Assert.IsNull(modelC.ModelBProperty); Assert.IsNull(modelC.ModelCProperty); var clonedModelC = SerializationTestHelper.SerializeAndDeserialize(modelC, SerializationFactory.GetBinarySerializer()); Assert.AreEqual("ModifiedA", clonedModelC.ModelAProperty); Assert.AreEqual("ModifiedB", clonedModelC.ModelBProperty); Assert.AreEqual("ModifiedC", clonedModelC.ModelCProperty); }