public void TestClassInterfaceInheritanceWithOrder() { var obj = new TestClassInterfaceInheritanceWithOrder { Id = 1, Id2 = 2 }; CheckCompatibilityWithDefaultSerializator(obj); CheckSerializationAndDeserializationByXml( @"<TestClassInterfaceInheritanceWithOrder type=""ExtendedXmlSerialization.Test.TestObject.TestClassInterfaceInheritanceWithOrder""> <Id2>2</Id2> <Id>1</Id> </TestClassInterfaceInheritanceWithOrder>", obj); }
public void TestClassInterfaceInheritanceWithOrder() { var expected = new TestClassInterfaceInheritanceWithOrder { Id = 1, Id2 = 2 }; var actual = new SerializationSupport().Assert( expected, @"<?xml version=""1.0"" encoding=""utf-8""?><TestClassInterfaceInheritanceWithOrder xmlns=""clr-namespace:ExtendedXmlSerializer.Tests.TestObject;assembly=ExtendedXmlSerializer.Tests""><Id2>2</Id2><Id>1</Id></TestClassInterfaceInheritanceWithOrder>" ); Assert.Equal(expected.Id2, actual.Id2); Assert.Equal(expected.Id, actual.Id); }