次の方法で共有


Partition Driver Test for Hard Drive (Compact 2013)

3/26/2014

The Partition Driver Test verifies the functionality of the application programming interface (API) set for a custom partition driver using a storage device such as a hard disk. This test covers the full API set for the partition driver. The test verifies that data is written to and read from the disk properly. The test also checks for overwritten partition boundaries.

This test is only necessary if you implement a custom partition driver. It is not necessary to run this test if you use the partition driver distributed with Windows Embedded Compact.

Test Prerequisites

Your device must meet the following requirements before you run this test.

The following table shows the hardware requirements for the Partition Driver Test.

Requirement

Description

Read/write storage media

Storage media that can be read from, written to, and partitioned, such as a hard disk.

The following table shows the software requirements for the Partition Driver Test.

Requirements

Description

Tux.exe

Tux test harness, required for executing the test

Kato.dll

Kato logging engine, required for logging test data

Msparttest.dll

Library containing the test

Partition driver

A compatible partition driver

Subtests

The table below lists the subtests included in this test.

SubTest ID

Description

5001

Partition driver store API:

Tests the partition manager storage API set by opening, formatting, and closing stores and by enumerating partitions on a store. This test case fails if any of the basic partition manager operations fail. The test case also fails if the partition information does not persist after a store is closed.

5002

Partition driver API:

Tests the partition manager API by creating, deleting, enumerating, and renaming partitions. This test case fails if any of the basic partition manager operations fail.

5101

Create, enumerate, and delete alternating partitions:

Creates partitions of increasing size until the disk is full and then verifies that all partitions are enumerated. The test then repeatedly enumerates and deletes alternating partitions until all partitions are deleted. This test case fails if problems occur in creating partitions. The test case also fails if there is a problem with simultaneously enumerating and deleting partitions.

5102

Create and rename partitions:

Creates a partition and then attempts to create a second partition using the same name as the first partition. The test then creates more partitions and attempts to assign names to the partitions that match the names of existing partitions. This test case fails if the partition driver allows multiple partitions to have the same name. The test case also fails if problems occur with creating and renaming a partition.

5103

Read/write and bounds check:

Verifies proper input and output on consecutive partitions. The test divides the disk into three partitions and verifies that input and output behaves properly on all partitions. This test case fails if the partition driver does not strictly enforce partition boundaries or if any problems occur with input and output.

5104

Verify disk info IOCTL:

Retrieves disk geometry information from the IOCTL_GET_DISK_INFO I/O control code for both the block and partition drivers. Verifies that the information is the same as the information stored in the PD_STOREINFO structure.

5105

Verify PD_STOREINFO:

Verifies that the information about free sectors in the PD_STOREINFO structure updates properly when partitions are created and deleted. This test case fails if the value for free sectors does not change by at least the number of sectors in the newly created or deleted partitions.

5106

Test partition boundaries for corruption:

Creates three partitions and verifies that it is not possible to perform out-of-bounds input and output operations on each partition.

Setting Up the Test

A hard drive must be connected and available on the Windows Embedded Compact device. The hard drive can be connected via IDE or SATA.

Running the Test

The Partition Driver Test executes the tux.exe -o -d msparttest.dll -c "/store DSK1:" command line on default execution. You may need to replace the "DSK1:" store information if your hard drive is assigned differently.

You can modify the test by editing the command line. For information about how to edit the command line for a test, see Editing the Command-Line for a Test. The following table shows the command line parameter for the Partition Driver Test.

Command line parameter

Description

/store

Specifies the name of storage device.

Note:Prior to running this test, be aware that all information on the storage device is destroyed. The test removes all partition information and writes to and reads from sectors on the storage device without preserving the contents of the sectors. We recommend that you back up data on all cards and disks that are attached to the tested device before running the test.

Verifying the Test

When the test completes running, verify that "PASS" appears in the test log for all subtests.

Troubleshooting the Test

You may need to replace the "DSK1:" store information in the command line if your hard drive is assigned differently.

See Also

Other Resources

Storage Media - Hard Drive Tests