Microsoft.Protocols.TestSuites.MS_OXCMAPIHTTP.MS_OXCMAPIHTTPAdapter.VerifyDisconnectSuccessResponseBody C# (CSharp) Method

VerifyDisconnectSuccessResponseBody() private method

Verify the Disconnect success response body related requirements.
private VerifyDisconnectSuccessResponseBody ( DisconnectSuccessResponseBody disconnectSuccessResponseBody ) : void
disconnectSuccessResponseBody DisconnectSuccessResponseBody The Disconnect success response body to be verified.
return void
        private void VerifyDisconnectSuccessResponseBody(DisconnectSuccessResponseBody disconnectSuccessResponseBody)
        {
            // Add the debug information
            this.Site.Log.Add(LogEntryKind.Debug, "Verify MS-OXCMAPIHTTP_R281");

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R281
            this.Site.CaptureRequirementIfIsInstanceOfType(
                disconnectSuccessResponseBody.StatusCode,
                typeof(uint),
                281,
                @"[In Disconnect Request Type Success Response Body] StatusCode (4 bytes): An unsigned integer that specifies the status of the request.");

            // Add the debug information
            this.Site.Log.Add(LogEntryKind.Debug, "Verify MS-OXCMAPIHTTP_R1363");

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R1363
            this.Site.CaptureRequirementIfAreEqual<uint>(
                0,
                disconnectSuccessResponseBody.StatusCode,
                1363,
                @"[In Disconnect Request Type Success Response Body] [StatusCode] This field MUST be set to 0x00000000.");

            // Add the debug information
            this.Site.Log.Add(LogEntryKind.Debug, "Verify MS-OXCMAPIHTTP_R288");

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R288
            this.Site.CaptureRequirementIfIsInstanceOfType(
                disconnectSuccessResponseBody.ErrorCode,
                typeof(uint),
                288,
                @"[In Disconnect Request Type Success Response Body] ErrorCode (4 bytes): An unsigned integer that specifies the return status of the operation.");

            // Add the debug information
            this.Site.Log.Add(LogEntryKind.Debug, "Verify MS-OXCMAPIHTTP_R289");

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R289
            this.Site.CaptureRequirementIfIsInstanceOfType(
                disconnectSuccessResponseBody.AuxiliaryBufferSize,
                typeof(uint),
                289,
                @"[In Disconnect Request Type Success Response Body] AuxiliaryBufferSize (4 bytes): An unsigned integer that specifies the size, in bytes, of the AuxiliaryBuffer field.");

            // Add the debug information
            this.Site.Log.Add(LogEntryKind.Debug, "Verify MS-OXCMAPIHTTP_R290");

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R290
            this.Site.CaptureRequirementIfIsInstanceOfType(
                disconnectSuccessResponseBody.AuxiliaryBuffer,
                typeof(byte[]),
                290,
                @"[In Disconnect Request Type Success Response Body] AuxiliaryBuffer (variable): An array of bytes that constitute the auxiliary payload data returned from the server.");

            // Add the debug information
            this.Site.Log.Add(
                LogEntryKind.Debug,
                "Verify MS-OXCMAPIHTTP_R1365, the length of AuxiliaryBuffer is {0}, the value of AuxiliaryBufferSize is {1}.",
                disconnectSuccessResponseBody.AuxiliaryBuffer.Length,
                disconnectSuccessResponseBody.AuxiliaryBufferSize);

            // Verify MS-OXCMAPIHTTP requirement: MS-OXCMAPIHTTP_R1365
            this.Site.CaptureRequirementIfAreEqual<uint>(
                disconnectSuccessResponseBody.AuxiliaryBufferSize,
                (uint)disconnectSuccessResponseBody.AuxiliaryBuffer.Length,
                1365,
                @"[In Disconnect Request Type Success Response Body] [AuxiliaryBuffer] The size of this field, in bytes, is specified by the AuxiliaryBufferSize field.");
        }
        #endregion
MS_OXCMAPIHTTPAdapter