GitHub+make: debug failing test, use official coveralls action

This commit is contained in:
Oliver Gugger 2025-02-18 19:16:10 +01:00
parent 576da75a07
commit 124137e31a
No known key found for this signature in database
GPG key ID: 8E4256593F177720
2 changed files with 15 additions and 12 deletions

View file

@ -218,11 +218,11 @@ jobs:
fail-fast: false fail-fast: false
matrix: matrix:
unit_type: unit_type:
- btcd unit-cover - unit-cover
- unit tags="kvdb_etcd" - unit tags="kvdb_etcd"
- unit tags="kvdb_postgres" - unit tags="kvdb_postgres"
- unit tags="kvdb_sqlite" - unit tags="kvdb_sqlite"
- btcd unit-race - unit-race
- unit-module - unit-module
steps: steps:
@ -260,12 +260,13 @@ jobs:
run: make ${{ matrix.unit_type }} run: make ${{ matrix.unit_type }}
- name: Send coverage - name: Send coverage
uses: ziggie1984/actions-goveralls@c440f43938a4032b627d2b03d61d4ae1a2ba2b5c uses: coverallsapp/github-action@v2
if: matrix.unit_type == 'btcd unit-cover' if: matrix.unit_type == 'unit-cover'
continue-on-error: true continue-on-error: true
with: with:
path-to-profile: coverage.txt file: coverage.txt
flag-name: 'unit' flag-name: 'unit'
format: 'golang'
parallel: true parallel: true
@ -317,10 +318,11 @@ jobs:
- name: Send coverage - name: Send coverage
if: ${{ contains(matrix.args, 'cover=1') }} if: ${{ contains(matrix.args, 'cover=1') }}
continue-on-error: true continue-on-error: true
uses: ziggie1984/actions-goveralls@c440f43938a4032b627d2b03d61d4ae1a2ba2b5c uses: coverallsapp/github-action@v2
with: with:
path-to-profile: coverage.txt file: coverage.txt
flag-name: 'itest-${{ matrix.name }}' flag-name: 'itest-${{ matrix.name }}'
format: 'golang'
parallel: true parallel: true
- name: Zip log files on failure - name: Zip log files on failure
@ -385,10 +387,11 @@ jobs:
- name: Send coverage - name: Send coverage
if: ${{ contains(matrix.args, 'cover=1') }} if: ${{ contains(matrix.args, 'cover=1') }}
continue-on-error: true continue-on-error: true
uses: ziggie1984/actions-goveralls@c440f43938a4032b627d2b03d61d4ae1a2ba2b5c uses: coverallsapp/github-action@v2
with: with:
path-to-profile: coverage.txt file: coverage.txt
flag-name: 'itest-${{ matrix.name }}' flag-name: 'itest-${{ matrix.name }}'
format: 'golang'
parallel: true parallel: true
- name: Zip log files on failure - name: Zip log files on failure
@ -552,7 +555,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Send coverage - name: Send coverage
uses: ziggie1984/actions-goveralls@c440f43938a4032b627d2b03d61d4ae1a2ba2b5c uses: coverallsapp/github-action@v2
continue-on-error: true continue-on-error: true
with: with:
parallel-finished: true parallel-finished: true

View file

@ -246,12 +246,12 @@ unit-debug: $(BTCD_BIN)
$(UNIT_DEBUG) $(UNIT_DEBUG)
#? unit-cover: Run unit tests in coverage mode #? unit-cover: Run unit tests in coverage mode
unit-cover: unit-cover: $(BTCD_BIN)
@$(call print, "Running unit coverage tests.") @$(call print, "Running unit coverage tests.")
$(UNIT_COVER) $(UNIT_COVER)
#? unit-race: Run unit tests in race detector mode #? unit-race: Run unit tests in race detector mode
unit-race: unit-race: $(BTCD_BIN)
@$(call print, "Running unit race tests.") @$(call print, "Running unit race tests.")
env CGO_ENABLED=1 GORACE="history_size=7 halt_on_errors=1" $(UNIT_RACE) env CGO_ENABLED=1 GORACE="history_size=7 halt_on_errors=1" $(UNIT_RACE)