Skip to content

Commit

Permalink
enhancement(5832): debugging ci issues
Browse files Browse the repository at this point in the history
  • Loading branch information
kaanyalti committed Dec 16, 2024
1 parent c1a0ecf commit 491761c
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions .buildkite/scripts/steps/integration_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,29 @@ STACK_PROVISIONER="${1:-"stateful"}"
MAGE_TARGET="${2:-"integration:test"}"
MAGE_SUBTARGET="${3:-""}"


# Override the stack version from `.package-version` contents
# There is a time when the current snapshot is not available on cloud yet, so we cannot use the latest version automatically
# This file is managed by an automation (mage integration:UpdateAgentPackageVersion) that check if the snapshot is ready.

STACK_VERSION="$(cat .package-version)"
if [[ -n "$STACK_VERSION" ]]; then
STACK_VERSION=${STACK_VERSION}"-SNAPSHOT"
STACK_VERSION=${STACK_VERSION}"-SNAPSHOT"
fi

# Run integration tests
set +e
AGENT_STACK_VERSION="${STACK_VERSION}" TEST_INTEG_CLEAN_ON_EXIT=true STACK_PROVISIONER="$STACK_PROVISIONER" SNAPSHOT=true mage $MAGE_TARGET $MAGE_SUBTARGET
AGENT_STACK_VERSION="${STACK_VERSION}" TEST_INTEG_CLEAN_ON_EXIT=true TEST_PACKAGES="rpm" TEST_GROUPS="rpm" STACK_PROVISIONER="$STACK_PROVISIONER" SNAPSHOT=true mage $MAGE_TARGET $MAGE_SUBTARGET
TESTS_EXIT_STATUS=$?
set -e

# HTML report
outputXML="build/TEST-go-integration.xml"

if [ -f "$outputXML" ]; then
go install github.com/alexec/junit2html@latest
junit2html < "$outputXML" > build/TEST-report.html
go install github.com/alexec/junit2html@latest
junit2html <"$outputXML" >build/TEST-report.html
else
echo "Cannot generate HTML test report: $outputXML not found"
echo "Cannot generate HTML test report: $outputXML not found"
fi

exit $TESTS_EXIT_STATUS

0 comments on commit 491761c

Please sign in to comment.