Skip to content

feat(ironic): Add node state metrics from versioned notifications #103

feat(ironic): Add node state metrics from versioned notifications

feat(ironic): Add node state metrics from versioned notifications #103

Workflow file for this run

name: Go Tests
on:
push:
branches:
- main
paths:
- "go/**"
- .github/workflows/go-test.yaml
pull_request:
paths:
- "go/**"
- .github/workflows/go-test.yaml
workflow_dispatch:
merge_group:
types: [checks_requested]
paths:
- "go/**"
- .github/workflows/go-test.yaml
permissions:
contents: read
jobs:
setup:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: List Applications
id: list_dirs
run: |
apps=$(ls -d go/* | xargs -n1 basename | jq -R -s -c 'split("\n")[:-1]')
echo "apps=${apps}"
# TODO: dexop does not pass tests
#echo "apps=%s" "${app_array}" >> "$GITHUB_OUTPUT"
echo "apps=[\"understackctl\"]" >> "$GITHUB_OUTPUT"
shell: bash
outputs:
apps: ${{ steps.list_dirs.outputs.apps }}
test:
runs-on: ubuntu-latest
needs: setup
strategy:
matrix:
app: ${{ fromJson(needs.setup.outputs.apps) }}
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6
with:
go-version-file: go/${{ matrix.app }}/go.mod
- name: Test ${{ matrix.app }}
working-directory: go/${{ matrix.app }}
run: go test -v ./...