ci/win: don't use lastexitcode hack on mingw build

The heck is for MSVC builds to workaround msbuild error detection for cmake.
This commit is contained in:
Jan Edmund Lazo 2018-04-11 14:03:21 -04:00
parent 7c8122f36d
commit bc43d2559f
1 changed files with 15 additions and 9 deletions

View File

@ -97,15 +97,21 @@ bin\nvim --version ; exitIfFailed
# Functional tests
# The $LastExitCode from MSBuild can't be trusted
$failed = $false
# Temporarily turn off tracing to reduce log file output
Set-PSDebug -Off
cmake --build . --config $cmakeBuildType --target functionaltest -- $cmakeGeneratorArgs |
foreach { $failed = $failed -or
$_ -match 'Running functional tests failed with error'; $_ }
Set-PSDebug -Trace 1
if ($failed) {
exit $LastExitCode
if ($compiler -eq 'MSVC') {
$failed = $false
# Temporarily turn off tracing to reduce log file output
Set-PSDebug -Off
cmake --build . --config $cmakeBuildType --target functionaltest -- $cmakeGeneratorArgs |
foreach { $failed = $failed -or
$_ -match 'Running functional tests failed with error'; $_ }
Set-PSDebug -Trace 1
if ($failed) {
exit $LastExitCode
}
}
else {
cmake --build . --config $cmakeBuildType --target functionaltest -- $cmakeGeneratorArgs
exitIfFailed
}