Import local Pester version before running tests

This commit is contained in:
Jason Shirk (POWERSHELL) committed 2016-06-24 14:03:30 -07:00
1 parent dbdd72b5d7
commit 283d596a20
1 file changed
+1 -1
+1 -1
View File
@@ -356,7 +356,7 @@ function Start-PSPester {
[string]$Directory = "$PSScriptRoot/test/powershell"
)
& (Get-PSOutput) -noprofile -c "Invoke-Pester $Flags $Directory/$Tests"
& (Get-PSOutput) -noprofile -c "Import-Module '$PSScriptRoot/src/Modules/Pester'; Invoke-Pester $Flags $Directory/$Tests"
if ($LASTEXITCODE -ne 0) {
throw "$LASTEXITCODE Pester tests failed"
}