Skip to content

Commit

Permalink
Debug
Browse files Browse the repository at this point in the history
  • Loading branch information
Vladimir Safonkin committed Feb 4, 2021
1 parent 44b8627 commit 7164f75
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions __tests__/verify-dotnet.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@ $version = & $dotnet --version | Out-String | ForEach-Object { $_.Trim() }
Write-Host "Version $version"
if ($version -notmatch $args[0])
{
Write-Host "PATH='$env:path'"
Write-Host "PATH='$env:PATH'"
throw "Unexpected version"
}

if ($args[1])
{
# SDKs are listed on multiple lines with the path afterwards in square brackets
$version = & $dotnet --list-sdks | ForEach-Object { $_.SubString(0, $_.IndexOf('[')).Trim() }
Write-Host "Version $version"
if (-not ($version -contains $args[1]))
$versions = & $dotnet --list-sdks | ForEach-Object { $_.SubString(0, $_.IndexOf('[')).Trim() } | Out-String
Write-Host "Version $versions"
if ($version -notmatch $args[1])
{
Write-Host "PATH='$env:path'"
Write-Host "PATH='$env:PATH'"
throw "Unexpected version"
}
}
Expand Down

0 comments on commit 7164f75

Please sign in to comment.