Esempio n. 1
0
        public void XmlSerialization_SwapAttributeOrder()
        {
            var start = new LocalDateTime(2013, 4, 12, 17, 53, 23, 123, 4567).InUtc().ToInstant();
            var end   = new LocalDateTime(2013, 10, 12, 17, 1, 2).InUtc().ToInstant();
            var value = new Interval(start, end);

            TestHelper.AssertParsableXml(value, "<value end=\"2013-10-12T17:01:02Z\" start=\"2013-04-12T17:53:23.1234567Z\" />");
        }
Esempio n. 2
0
        public void XmlSerialization_ExtraContent()
        {
            var start = new LocalDateTime(2013, 4, 12, 17, 53, 23, 123, 4567).InUtc().ToInstant();
            var end   = new LocalDateTime(2013, 10, 12, 17, 1, 2).InUtc().ToInstant();
            var value = new Interval(start, end);

            TestHelper.AssertParsableXml(value,
                                         "<value start=\"2013-04-12T17:53:23.1234567Z\" end=\"2013-10-12T17:01:02Z\">Text<child attr=\"value\"/>Text 2</value>");
        }