Skip to content

Commit

Permalink
chore(ci): display test summary output
Browse files Browse the repository at this point in the history
  • Loading branch information
jharley committed Jul 30, 2024
1 parent ef618d2 commit bc43c06
Showing 1 changed file with 22 additions and 6 deletions.
28 changes: 22 additions & 6 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ jobs:
env:
HONEYCOMB_API_KEY: ${{ secrets.HONEYCOMB_API_KEY }}
HONEYCOMB_DATASET: testacc
run: ./scripts/setup-testsuite-dataset
run: |
go install github.com/jstemmer/go-junit-report/v2@latest
./scripts/setup-testsuite-dataset
- name: Run client acceptance tests
timeout-minutes: 10
Expand All @@ -66,7 +68,7 @@ jobs:
HONEYCOMB_KEY_ID: ${{ secrets.HONEYCOMB_KEY_ID }}
HONEYCOMB_KEY_SECRET: ${{ secrets.HONEYCOMB_KEY_SECRET }}
HONEYCOMB_DATASET: testacc
run: go test -v -coverprofile=client-coverage.txt -covermode=atomic ./client/...
run: go test -v -coverprofile=client-coverage.txt -covermode=atomic ./client/... | go-junit-report -set-exit-code > client-report.xml

- uses: hashicorp/setup-terraform@v3
with:
Expand All @@ -82,7 +84,7 @@ jobs:
HONEYCOMB_DATASET: testacc
TF_ACC: 1
TF_ACC_TERRAFORM_VERSION: ${{ env.TERRAFORM_VERSION }}
run: go test -v -coverprofile=tf-coverage.txt -covermode=atomic ./internal/... ./honeycombio/...
run: go test -v -coverprofile=tf-coverage.txt -covermode=atomic ./internal/... ./honeycombio/... | go-junit-report -set-exit-code > provider-report.xml

- name: Cleanup Dangling Resources
if: ${{ always() }}
Expand All @@ -94,6 +96,12 @@ jobs:
HONEYCOMB_DATASET: testacc
run: make sweep

- name: Test Summary
if: always()
uses: test-summary/action@v2
with:
paths: "*-report.xml"

- name: Generate Coverage Report
uses: codecov/codecov-action@v4.5.0
with:
Expand Down Expand Up @@ -123,7 +131,9 @@ jobs:
HONEYCOMB_API_ENDPOINT: https://api.eu1.honeycomb.io
HONEYCOMB_API_KEY: ${{ secrets.HONEYCOMB_API_KEY_EU }}
HONEYCOMB_DATASET: testacc
run: ./scripts/setup-testsuite-dataset
run: |
go install github.com/jstemmer/go-junit-report/v2@latest
./scripts/setup-testsuite-dataset
- name: Run client acceptance tests
timeout-minutes: 10
Expand All @@ -133,7 +143,7 @@ jobs:
HONEYCOMB_KEY_ID: ${{ secrets.HONEYCOMB_KEY_ID_EU }}
HONEYCOMB_KEY_SECRET: ${{ secrets.HONEYCOMB_KEY_SECRET_EU }}
HONEYCOMB_DATASET: testacc
run: go test -v -coverprofile=client-coverage.txt -covermode=atomic ./client/...
run: go test -v -coverprofile=client-coverage.txt -covermode=atomic ./client/... | go-junit-report -set-exit-code > client-report.xml

- uses: hashicorp/setup-terraform@v3
with:
Expand All @@ -150,7 +160,7 @@ jobs:
HONEYCOMB_DATASET: testacc
TF_ACC: 1
TF_ACC_TERRAFORM_VERSION: ${{ env.TERRAFORM_VERSION }}
run: go test -v -coverprofile=tf-coverage.txt -covermode=atomic ./internal/... ./honeycombio/...
run: go test -v -coverprofile=tf-coverage.txt -covermode=atomic ./internal/... ./honeycombio/... | go-junit-report -set-exit-code > provider-report.xml

- name: Cleanup Dangling Resources
if: ${{ always() }}
Expand All @@ -163,6 +173,12 @@ jobs:
HONEYCOMB_DATASET: testacc
run: make sweep

- name: Test Summary
if: always()
uses: test-summary/action@v2
with:
paths: "*-report.xml"

- name: Generate Coverage Report
uses: codecov/codecov-action@v4.5.0
with:
Expand Down

0 comments on commit bc43c06

Please sign in to comment.