Update Go.Tests.ps1
This commit is contained in:
parent
ba76e8ae2e
commit
e60f915e0b
|
@ -25,7 +25,7 @@ Describe "Go" {
|
|||
|
||||
It "version is correct" {
|
||||
[version]$Version = $env:VERSION
|
||||
$versionOutput = (Invoke-Expression -Command "go version") -split " " | Select-Object -Index 2 -replace "go", ""
|
||||
$versionOutput = Invoke-Expression -Command "go version"
|
||||
$finalVersion = $Version.ToString(3)
|
||||
If ($Version.Build -eq "0"){
|
||||
$finalVersion = $Version.ToString(2)
|
||||
|
@ -33,6 +33,7 @@ Describe "Go" {
|
|||
$versionOutput | Should -Match $finalVersion
|
||||
}
|
||||
|
||||
|
||||
It "is used from tool-cache" {
|
||||
$goPath = (Get-Command "go").Path
|
||||
$goPath | Should -Not -BeNullOrEmpty
|
||||
|
|
Loading…
Reference in New Issue