mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Add missing directory fixing go.etcd.io/etcd/etcdutl/v3/::etcdutl/ Note: we have some of the tests written in a way that is non-deterministic across runs, thus, even when there is no code changes there might still have slight variation for test coverage [2] Reference: [1] https://github.com/etcd-io/etcd/issues/18131 [2] https://docs.codecov.com/docs/unexpected-coverage-changes#reasons-for-indirect-changes Signed-off-by: Chun-Hung Tseng <henrybear327@gmail.com>
35 lines
997 B
YAML
35 lines
997 B
YAML
---
|
|
name: Coverage
|
|
on: [push, pull_request]
|
|
permissions: read-all
|
|
jobs:
|
|
coverage:
|
|
# this is to prevent the job to run at forked projects
|
|
if: github.repository == 'etcd-io/etcd'
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
target:
|
|
- linux-amd64-coverage
|
|
steps:
|
|
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
|
|
- id: goversion
|
|
run: echo "goversion=$(cat .go-version)" >> "$GITHUB_OUTPUT"
|
|
- uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7 # v5.0.1
|
|
with:
|
|
go-version: ${{ steps.goversion.outputs.goversion }}
|
|
- env:
|
|
TARGET: ${{ matrix.target }}
|
|
run: |
|
|
mkdir "${TARGET}"
|
|
case "${TARGET}" in
|
|
linux-amd64-coverage)
|
|
GOARCH=amd64 ./scripts/codecov_upload.sh
|
|
;;
|
|
*)
|
|
echo "Failed to find target"
|
|
exit 1
|
|
;;
|
|
esac
|