Test-WtIntuneWin
Test if a package will install
Use the Windows Sandbox to test if the provided installer arguments will make it install silently and if it exists with the expected exit code.
Syntax
PackageFolder (default)
Test-WtIntuneWin -PackageFolder <String> [-InstallerArguments <String>] [-Clean] [-Sleep <Int32>]
Parameter | Req. | Type | Description |
---|---|---|---|
-PackageFolder | ✅ | String | The folder where the package is |
-InstallerArguments | ❌ | String | Override the installer arguments |
-Clean | ❌ | Switch | Clean the test files after run |
-Sleep | ❌ | Int32 | Sleep for x seconds before auto shutdown |
IntuneWin
Test-WtIntuneWin -IntuneWinFile <String> [-InstallerFilename <String>] [-InstallerArguments <String>] [-Clean] [-Sleep <Int32>]
Parameter | Req. | Type | Description |
---|---|---|---|
-IntuneWinFile | ✅ | String | The IntuneWin file to test |
-InstallerFilename | ❌ | String | The installer filename (if not set correctly inside the intunewin) |
-InstallerArguments | ❌ | String | The installer arguments (if you want it to execute silently) |
-Clean | ❌ | Switch | Clean the test files after run |
-Sleep | ❌ | Int32 | Sleep for x seconds before auto shutdown |
WinGet
Test-WtIntuneWin -PackageId <String> -Version <String> -RootPackageFolder <String> [-Clean] [-Sleep <Int32>]
Parameter | Req. | Type | Description |
---|---|---|---|
-PackageId | ✅ | String | The package id to upload to Intune. |
-Version | ✅ | String | The version to upload to Intune |
-RootPackageFolder | ✅ | String | The Root folder where all the package live in. |
-Clean | ❌ | Switch | Clean the test files after run |
-Sleep | ❌ | Int32 | Sleep for x seconds before auto shutdown |
Examples
Test OhMyPosh version 22.0.3
Test a packaged installer in sandbox
Test-WtIntuneWin -PackageFolder "D:\packages\JanDeDobbeleer.OhMyPosh\22.0.3"