Export-HwCertTestCollectionToXml

Export-HwCertTestCollectionToXml

Exports a test collection to an .xml file.

Syntaxe

Parameter Set: Default
Export-HwCertTestCollectionToXml [-InputObject] <TestCollectionRecord[]> -Output <String> [-TestPassIdentifier <String> ] [ <CommonParameters>]

Description détaillée

The Export-HwCertTestCollectionToXml cmdlet exports a test collection to an .xml file. For more information, see Windows Hardware Certification Kit (HCK) (https://msdn.microsoft.com/en-us/library/windows/hardware/hh833788.aspx) in the Microsoft Developer Network (MSDN) Library.

After you export a test collection, you can use the Merge-HwCertTestCollectionFromXml cmdlet to merge it with other test collections. Use the Import-HwCertTestCollectionFromXml cmdlet to import test collections that you previously exported. After you import a test collection, you can filter it by using TestCollectionRecord properties, and then use this cmdlet to export the filtered test collection.

Paramètres

-InputObject<TestCollectionRecord[]>

Specifies an array of TestCollectionRecord objects. To obtain a TestCollectionRecord object, use the New-HwCertTestCollection cmdlet. You can also use the Merge-HwCertTestCollectionFromXml cmdlet or the Merge-HwCertTestCollectionFromHckx cmdlet to obtain merged results, as a TestCollectionRecord object.

Alias

none

Obligatoire ?

true

Position ?

1

Valeur par défaut

none

Accepter l’entrée de pipeline ?

True (ByValue)

Accepter les caractères génériques ?

false

-Output<String>

Specifies a full path for the exported file.

Alias

Path

Obligatoire ?

true

Position ?

named

Valeur par défaut

none

Accepter l’entrée de pipeline ?

false

Accepter les caractères génériques ?

false

-TestPassIdentifier<String>

Specifies a case-sensitive identifier that you assign to the exported test collection.

Alias

TP,ID

Obligatoire ?

false

Position ?

named

Valeur par défaut

none

Accepter l’entrée de pipeline ?

false

Accepter les caractères génériques ?

false

<CommonParameters>

Cette applet de commande prend en charge les paramètres courants : -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer et -OutVariable. Pour plus d’informations, consultez about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Entrées

Le type d’entrée correspond au type des objets que vous pouvez transmettre à l’applet de commande.

Sorties

Le type de sortie est le type des objets émis par l’applet de commande.

  • Microsoft.Windows.Kits.Hardware.Certification.TestCollectionRecord

Exemples

Example 1: Filter a test collection

This command imports a test collection, finds the results that belong to a specified content level, and exports a new test collection .xml file that contains only those results. The command uses the Import-HwCertTestCollectionFromXml cmdlet to import a test collection named All.xml, as a TestCollectionRecord object, and then passes that object to the Where-Object cmdlet by using the pipeline operator. The Where-Object cmdlet filters the imported object for results belong to the Basic content level. For more information, type Get-Help Where-Object. The command passes those items to the Export-HwCertTestCollectionToXml cmdlet, which exports the test collection to the file named Basic.xml.

PS C:\> Import-HwCertTestCollectionFromXml -Input "C:\Temp\All.xml" | Where-Object { $_.ContentLevelSet.Contains("Basic") } | Export-HwCertTestCollectionToXml -Output "C:\Temp\Basic.xml"

Rubriques connexes

Import-HwCertTestCollectionFromXml

New-HwCertTestCollection

Merge-HwCertTestCollectionFromXml

Merge-HwCertTestCollectionFromHckx