Skip to content

Commit

Permalink
ci: enable automated test with PR label
Browse files Browse the repository at this point in the history
a PR with the label 'release-test' will trigger a run on the hlab

Signed-off-by: Emanuele Di Pascale <emanuele@githedgehog.com>
  • Loading branch information
edipascale committed Mar 5, 2025
1 parent 6b7da22 commit e2d0f80
Showing 1 changed file with 23 additions and 3 deletions.
26 changes: 23 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,9 @@ jobs:
hlab:
runs-on: hlab
timeout-minutes: 60
timeout-minutes: 120
env:
RunReleaseTest: ${{ github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'release-test') }}
needs:
- test
- builds
Expand Down Expand Up @@ -438,10 +440,28 @@ jobs:
run: |
just --timestamp oci_repo=127.0.0.1:30000 oci=http push
- name: hhfab init and vlab up
- name: hhfab release test
env:
HHFAB_REG_REPO: 127.0.0.1:30000
HHFAB_VLAB_COLLECT: true
if: ${{ env.RunReleaseTest }}
run: |
source "./lab-ci/envs/$KUBE_NODE/source.sh"
bin/hhfab init -v --dev --include-onie=${{ matrix.includeonie }} -w "./lab-ci/envs/$KUBE_NODE/wiring.yaml"
bin/hhfab vlab up -v --ready switch-reinstall --ready inspect --ready setup-vpcs --ready test-connectivity --ready release-test --ready exit --mode=${{ matrix.buildmode }}
cat release-test.xml
- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: ${{ env.RunReleaseTest }}
with:
files: release-test.xml

- name: hhfab basic test-connectivity
env:
HHFAB_REG_REPO: 127.0.0.1:30000
HHFAB_VLAB_COLLECT: true
if: ${{ !env.RunReleaseTest }}
run: |
source "./lab-ci/envs/$KUBE_NODE/source.sh"
bin/hhfab init -v --dev --include-onie=${{ matrix.includeonie }} -w "./lab-ci/envs/$KUBE_NODE/wiring.yaml"
Expand All @@ -462,7 +482,7 @@ jobs:
- name: Setup tmate session for debug
if: ${{ failure() && github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
timeout-minutes: 120
with:
limit-access-to-actor: true

Expand Down

0 comments on commit e2d0f80

Please sign in to comment.