Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.18](backport #6662) [CI] Fix throttled windows test failures #6696

Merged
merged 5 commits into from
Feb 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions .buildkite/scripts/integration-tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ $env:AGENT_VERSION = $PACKAGE_VERSION
$env:SNAPSHOT = $true

echo "~~~ Building test binaries"
mage build:testBinaries
& mage build:testBinaries
if ($LASTEXITCODE -ne 0) {
Write-Error "Failed to build test binaries"
exit 1
}
$osInfo = (Get-CimInstance Win32_OperatingSystem).Caption + " " + (Get-CimInstance Win32_OperatingSystem).OSArchitecture -replace " ", "_"
$root_suffix=""
if ($TEST_SUDO -eq "true") {
Expand All @@ -31,10 +35,12 @@ if ($TEST_SUDO -eq "true") {
$fully_qualified_group_name="${GROUP_NAME}${root_suffix}_${osInfo}"
$outputXML = "build/${fully_qualified_group_name}.integration.xml"
$outputJSON = "build/${fully_qualified_group_name}.integration.out.json"
$TestsExitCode = 0
try {
Get-Ess-Stack -StackVersion $PACKAGE_VERSION
Write-Output "~~~ Running integration test group: $GROUP_NAME as user: $env:USERNAME"
gotestsum --no-color -f standard-quiet --junitfile "${outputXML}" --jsonfile "${outputJSON}" -- -tags=integration -shuffle=on -timeout=2h0m0s "github.com/elastic/elastic-agent/testing/integration" -v -args "-integration.groups=$GROUP_NAME" "-integration.sudo=$TEST_SUDO"
& gotestsum --no-color -f standard-quiet --junitfile "${outputXML}" --jsonfile "${outputJSON}" -- -tags=integration -shuffle=on -timeout=2h0m0s "github.com/elastic/elastic-agent/testing/integration" -v -args "-integration.groups=$GROUP_NAME" "-integration.sudo=$TEST_SUDO"
$TestsExitCode = $LASTEXITCODE
} finally {
ess_down

Expand All @@ -46,3 +52,7 @@ try {
Write-Output "Cannot generate HTML test report: $outputXML not found"
}
}

if ($TestsExitCode -ne 0) {
exit 1
}
Loading