mirror of
https://github.com/actions/runner-images.git
synced 2025-12-20 06:35:47 +00:00
[Windows] Implement new directories hierarchy (#8616)
This commit is contained in:
committed by
GitHub
parent
84a7deae24
commit
d1f2c9a3be
37
images/windows/scripts/tests/VisualStudio.Tests.ps1
Normal file
37
images/windows/scripts/tests/VisualStudio.Tests.ps1
Normal file
@@ -0,0 +1,37 @@
|
||||
Describe "Visual Studio" {
|
||||
Context "Basic" {
|
||||
It "Catalog.json" {
|
||||
Get-VsCatalogJsonPath | Should -Exist
|
||||
}
|
||||
|
||||
It "Devenv.exe" {
|
||||
$vsInstallRoot = (Get-VisualStudioInstance).InstallationPath
|
||||
$devenvexePath = "${vsInstallRoot}\Common7\IDE\devenv.exe"
|
||||
$devenvexePath | Should -Exist
|
||||
}
|
||||
}
|
||||
|
||||
Context "Visual Studio components" {
|
||||
$expectedComponents = Get-ToolsetContent | Select-Object -ExpandProperty visualStudio | Select-Object -ExpandProperty workloads
|
||||
$testCases = $expectedComponents | ForEach-Object { @{ComponentName = $_} }
|
||||
BeforeAll {
|
||||
$installedComponents = Get-VisualStudioComponents | Select-Object -ExpandProperty Package
|
||||
}
|
||||
|
||||
It "<ComponentName>" -TestCases $testCases {
|
||||
$installedComponents | Should -Contain $ComponentName
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Describe "Windows 10 SDK" {
|
||||
It "Verifies 17763 SDK is installed" -Skip:(Test-IsWin19) {
|
||||
"${env:ProgramFiles(x86)}\Windows Kits\10\DesignTime\CommonConfiguration\Neutral\UAP\10.0.17763.0\UAP.props" | Should -Exist
|
||||
}
|
||||
}
|
||||
|
||||
Describe "Windows 11 SDK" {
|
||||
It "Verifies 22621 SDK is installed" -Skip:(Test-IsWin22) {
|
||||
"${env:ProgramFiles(x86)}\Windows Kits\10\DesignTime\CommonConfiguration\Neutral\UAP\10.0.22621.0\UAP.props" | Should -Exist
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user