Skip to content

Commit c6d6ad7

Browse files
author
Andrew
committed
Updated WinPS-adapter tests
1 parent 50e9a0a commit c6d6ad7

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

powershell-adapter/Tests/win_powershellgroup.tests.ps1

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,18 @@ Describe 'PowerShell adapter resource tests' {
1111
$env:PSModulePath += [System.IO.Path]::PathSeparator + $PSScriptRoot
1212

1313
$winpsConfigPath = Join-path $PSScriptRoot "winps_resource.dsc.yaml"
14-
$cacheFilePath_v5 = Join-Path $env:LocalAppData "dsc" "WindowsPSAdapterCache.json"
14+
if ($isWindows) {
15+
$cacheFilePath_v5 = Join-Path $env:LocalAppData "dsc" "WindowsPSAdapterCache.json"
16+
}
1517
}
1618
AfterAll {
1719
$env:PSModulePath = $OldPSModulePath
1820
}
1921

2022
BeforeEach {
21-
Remove-Item -Force -ea SilentlyContinue -Path $cacheFilePath_v5
23+
if ($isWindows) {
24+
Remove-Item -Force -ea SilentlyContinue -Path $cacheFilePath_v5
25+
}
2226
}
2327

2428
It 'Windows PowerShell adapter supports File resource' -Skip:(!$IsWindows){

0 commit comments

Comments
 (0)