Beispiel #1
0
        public void Deserialize_SampleFile_MeasureWithDisplayFolderRoot()
        {
            int testNr = 4;

            // Create an instance of the XmlSerializer specifying type and namespace.
            TestSuiteXml ts = DeserializeSample();

            // Check the properties of the object.
            Assert.That(ts.Tests[testNr].Systems[0], Is.TypeOf <StructureXml>());
            Assert.That(((StructureXml)ts.Tests[testNr].Systems[0]).Item, Is.TypeOf <MeasureXml>());

            MeasureXml item = (MeasureXml)((StructureXml)ts.Tests[testNr].Systems[0]).Item;

            Assert.That(item.DisplayFolder, Is.Empty);
            Assert.That(item.Specification.IsDisplayFolderSpecified, Is.True);
        }
Beispiel #2
0
        public void Deserialize_SampleFile_MeasureGroupNotSpecified()
        {
            int testNr = 1;

            // Create an instance of the XmlSerializer specifying type and namespace.
            TestSuiteXml ts = DeserializeSample();

            // Check the properties of the object.
            Assert.That(ts.Tests[testNr].Systems[0], Is.TypeOf <StructureXml>());
            Assert.That(((StructureXml)ts.Tests[testNr].Systems[0]).Item, Is.TypeOf <MeasureXml>());

            MeasureXml item = (MeasureXml)((StructureXml)ts.Tests[testNr].Systems[0]).Item;

            Assert.That(item.MeasureGroup, Is.Null.Or.Empty);
            Assert.That(item.Specification.IsMeasureGroupSpecified, Is.False);
        }