Skip to content

Skip tests-e2e-scenarios-bare-metal when version.go changes #17391

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
11 changes: 10 additions & 1 deletion .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
path: ${{ env.GOPATH }}/src/k8s.io/kops
fetch-depth: 2

- name: Set up go
uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b
Expand All @@ -29,9 +30,17 @@ jobs:
- name: tests/e2e/scenarios/bare-metal/run-test
working-directory: ${{ env.GOPATH }}/src/k8s.io/kops
run: |
timeout 60m tests/e2e/scenarios/bare-metal/run-test
CHANGED_VERSION=$(git diff --name-only HEAD~1 | grep -E '^kops-version\.go$')
if [ -z "${CHANGED_VERSION}" ]
then
echo "running metal test"
timeout 60m tests/e2e/scenarios/bare-metal/run-test
else
echo "kops-version.go has been modified, skipping metal test"
fi
env:
ARTIFACTS: /tmp/artifacts

- name: Archive production artifacts
if: always()
uses: actions/upload-artifact@v4
Expand Down
Loading