/// <summary> /// This method is used to test Cell Knowledge Entry related adapter requirements. /// </summary> /// <param name="instance">Specify the instance which need to be verified.</param> /// <param name="site">Specify the ITestSite instance.</param> public void VerifyCellKnowledgeEntry(CellKnowledgeEntry instance, ITestSite site) { // If the instance is not null and there are no parsing errors, then the Cell Knowledge Entry related adapter requirements can be directly captured. if (null == instance) { site.Assert.Fail("The instance of type CellKnowledgeEntry is null due to parsing error or type casting error."); } // Verify the stream object header related requirements. this.ExpectStreamObjectHeaderStart(instance.StreamObjectHeaderStart, instance.GetType(), site); // Capture requirement MS-FSSHTTPB_R560, if stream object start type is StreamObjectHeaderStart16bit. site.CaptureRequirementIfAreEqual <Type>( typeof(StreamObjectHeaderStart16bit), instance.StreamObjectHeaderStart.GetType(), "MS-FSSHTTPB", 560, @"[In Cell Knowledge Entry] Cell Knowledge Entry (2 bytes): A 16-bit stream object header (section 2.2.1.5.1), that specifies a cell knowledge entry."); // Directly capture requirement MS-FSSHTTPB_R561, if there are no parsing errors. site.CaptureRequirement( "MS-FSSHTTPB", 561, @"[In Cell Knowledge Entry] Serial Number (variable): A serial number (section 2.2.1.9) that specifies the cell."); // Verify the stream object header end related requirements. this.ExpectSingleObject(instance.StreamObjectHeaderStart, site); }
/// <summary> /// This method is used to test Cell Knowledge Entry related adapter requirements. /// </summary> /// <param name="instance">Specify the instance which need to be verified.</param> /// <param name="site">Specify the ITestSite instance.</param> public void VerifyCellKnowledgeEntry(CellKnowledgeEntry instance, ITestSite site) { // If the instance is not null and there are no parsing errors, then the Cell Knowledge Entry related adapter requirements can be directly captured. if (null == instance) { site.Assert.Fail("The instance of type CellKnowledgeEntry is null due to parsing error or type casting error."); } // Verify the stream object header related requirements. this.ExpectStreamObjectHeaderStart(instance.StreamObjectHeaderStart, instance.GetType(), site); // Capture requirement MS-FSSHTTPB_R560, if stream object start type is StreamObjectHeaderStart16bit. site.CaptureRequirementIfAreEqual<Type>( typeof(StreamObjectHeaderStart16bit), instance.StreamObjectHeaderStart.GetType(), "MS-FSSHTTPB", 560, @"[In Cell Knowledge Entry] Cell Knowledge Entry (2 bytes): A 16-bit stream object header (section 2.2.1.5.1), that specifies a cell knowledge entry."); // Directly capture requirement MS-FSSHTTPB_R561, if there are no parsing errors. site.CaptureRequirement( "MS-FSSHTTPB", 561, @"[In Cell Knowledge Entry] Serial Number (variable): A serial number (section 2.2.1.9) that specifies the cell."); // Verify the stream object header end related requirements. this.ExpectSingleObject(instance.StreamObjectHeaderStart, site); }