fix(ci): use go-test-coverage binary directly to fix Gitea Actions (#303)
authz_client / vulnerabilities (push) Successful in 1m37s
Release / release (push) Failing after 1m2s
authz_client / test (push) Successful in 2m44s
pre-commit / pre-commit (push) Failing after 14m25s

## Summary

- `vladopajic/go-test-coverage@v2` (v2.18.5+, released 2026-04-26/27) restructured its composite action to pass inputs via env-var mapping. Gitea `act_runner` doesn't expand `${{ }}` expressions inside docker-action `env:` blocks reliably, so the literal string `${{ inputs.config }}` reached the binary and broke the 'Check coverage' step.
- Replace the action with a direct `go install` + binary invocation (matching the established Frostmoln pattern).
- Use `--github-action-output` to expose `total-coverage` as a step output, replacing the manual `go tool cover -func | grep | awk` calculations.
- Baseline artifact now stores the percentage directly instead of the full coverage profile.
- Bump `go` directive in `go.mod` from 1.22.12 → 1.26.2 (matching toolchain) — we are the sole consumers of this module.

## Test plan

- [x] `prek run --all-files` passes
- [ ] CI passes on this PR
- [ ] After merge, baseline artifact format propagates on next push to main

Reviewed-on: #303
This commit was merged in pull request #303.
This commit is contained in:
2026-04-29 06:06:22 +00:00
parent 775d25cb59
commit f9a89b64be
2 changed files with 12 additions and 18 deletions
+1 -3
View File
@@ -1,8 +1,6 @@
module gitea.unbound.se/shiny/authz_client
go 1.22.12
toolchain go1.26.2
go 1.26.2
require (
github.com/sparetimecoders/goamqp v0.3.3