다음을 통해 공유


Test Cases for the OAL IOCTL Test (Windows CE 5.0)

Send Feedback

The OAL IOCTL Test provides test cases that verify normal operation and test cases that force a failure. If a test case that verifies normal operation fails, you might see the cascading failure of other test cases. Test case failures of this type indicate that the required IOCTL is not implemented. If test cases fail, investigate first the failures in test cases that verify normal operation.

The following table shows test cases for the OAL IOCTL Test.

Test case Description
501: IOCTL_HAL_GET_DEVICEID - Normal Operation Attempts to call the IOCTL_HAL_GET_DEVICEID IOCTL. If the call succeeds, the test results display the data returned by the IOCTL.
502: IOCTL_HAL_GET_DEVICEID - Normal Operation No lpBytesReturned Calls the IOCTL_HAL_GET_DEVICEID IOCTL with the lpBytesReturned parameter set to NULL, and compares this case to the case in which this parameter is not NULL.
503: IOCTL_HAL_GET_DEVICEID - Normal Operation Check Query Verifies that the IOCTL_HAL_GET_DEVICEID IOCTL returns the correct size of the data buffer that it passes.
507: IOCTL_HAL_GET_DEVICEID - Force Failure - Query on Large Buffer Sends a buffer that is the correct size to the IOCTL_HAL_GET_DEVICEID IOCTL, but sets the value of the dwSize flag to zero. This test case verifies that the IOCTL returns the size and does not return the data structure.
508: IOCTL_HAL_GET_DEVICEID - Force Failure - outBufSize = 0 Sets to zero the nOutBufSize parameter for the IOCTL_HAL_GET_DEVICEID IOCTL to force a failure.

If this test case fails, verify that your code assesses the value of the nOutBufSize parameter before writing to the buffer.

509: IOCTL_HAL_GET_DEVICEID - Force Failure - outBufSize = 1 Sets to 1 the value of the nOutBufSize parameter for the IOCTL_HAL_GET_DEVICEID IOCTL to force a failure.
510: IOCTL_HAL_GET_DEVICEID - Force Failure - outBufSize One Less Sets the value of the nOutBufSize parameter for the IOCTL_HAL_GET_DEVICEID IOCTL to a value that is one less than the value required to force a failure.

If this test case fails, your code might not be using the correct operator to make a comparison. For example, the code might use a less-than operator instead of a less-than-or-equal-to operator.

511: IOCTL_HAL_GET_DEVICEID - Normal Operation - outBufSize One Greater Sets the value of the nOutBufSize parameter for the IOCTL_HAL_GET_DEVICEID IOCTL to a value that is one greater than is required.

If this test case fails, your code might be incorrectly forcing the buffer to be exactly the correct size.

512: IOCTL_HAL_GET_DEVICEID - Force Failure - outBuf is NULL Confirms that setting to NULL the value of the lpOutBuf parameter for the IOCTL_HAL_GET_DEVICEID IOCTL forces a failure.
601: IOCTL_HAL_GET_UUID - Normal Operation Attempts to call the IOCTL_HAL_GET_UUID IOCTL. If the call succeeds, the test results display the universally unique identifier (UUID) returned by the IOCTL.
602: IOCTL_HAL_GET_UUID - Normal Operation No lpBytesReturned Confirms that setting to NULL the lpBytesReturned parameter for the IOCTL_HAL_GET_UUID IOCTL does not affect the returned data structure.
606: IOCTL_HAL_GET_UUID - Force Failure - outBufSize = 0 Sets to zero the nOutBufSize parameter for the IOCTL_HAL_GET_UUID IOCTL to force a failure.

If this test case fails, verify that your code assesses the value of the nOutBufSize parameter before writing to the buffer.

607: IOCTL_HAL_GET_UUID - Force Failure - outBufSize = 1 Sets to 1 the value of the nOutBufSize parameter for the IOCTL_HAL_GET_UUID IOCTL to force a failure.
608: IOCTL_HAL_GET_UUID - Force Failure - outBufSize One Less Sets the value of the nOutBufSize parameter for the IOCTL_HAL_GET_UUID IOCTL to a value that is one less than the value required to force a failure.

If this test case fails, your code might not be using the correct operator to make a comparison. For example, the code might use a less-than operator instead of a less-than-or-equal-to operator.

609: IOCTL_HAL_GET_UUID - Normal Operation - outBufSize One Greater Sets the value of the nOutBufSize parameter for the IOCTL_HAL_GET_UUID IOCTL to a value that is one greater than is required.

If this test case fails, your code might be incorrectly forcing the buffer to be exactly the correct size.

610: IOCTL_HAL_GET_UUID - Force Failure - outBuf is NULL Confirms that setting to NULL the value of the lpOutBuf parameter for the IOCTL_HAL_GET_UUID IOCTL forces a failure.
611: IOCTL_HAL_GET_UUID - Normal Operation - Alignment 8th Bit Confirms that the IOCTL_HAL_GET_UUID IOCTL correctly returns data when the buffer is not DWORD aligned.
612: IOCTL_HAL_GET_UUID - Normal Operation - Alignment 16th Bit Confirms that the IOCTL_HAL_GET_UUID IOCTL correctly returns data when the buffer is not DWORD aligned.
613: IOCTL_HAL_GET_UUID - Normal Operation - Alignment 24th Bit Confirms that the IOCTL_HAL_GET_UUID IOCTL correctly returns data when the buffer is not DWORD aligned.

See Also

OAL IOCTL Test | IOCTL_HAL_GET_DEVICEID | IOCTL_HAL_GET_UUID

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.