public void DefaultSubtypeForwardTest() { var expected = new DefaultSubtypeContainerClass { Value = new SubclassA() }; var actual = Roundtrip(expected); Assert.AreEqual(1, actual.Indicator); Assert.AreEqual(typeof(SubclassA), actual.Value.GetType()); }
public void DefaultSubtypeAllowOnSerialize() { var expected = new DefaultSubtypeContainerClass { Indicator = 33, Value = new DefaultSubtypeClass() }; var actual = Roundtrip(expected); Assert.AreEqual(33, actual.Indicator); Assert.AreEqual(typeof(DefaultSubtypeClass), actual.Value.GetType()); }