mirror of
https://github.com/k8sgpt-ai/k8sgpt.git
synced 2026-05-19 14:11:16 +00:00
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
31 lines
687 B
YAML
31 lines
687 B
YAML
name: Run tests
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
env:
|
|
GO_VERSION: "~1.22"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5
|
|
with:
|
|
go-version: ${{ env.GO_VERSION }}
|
|
|
|
- name: Run test
|
|
run: go test ./... -coverprofile=coverage.txt
|
|
- name: Upload coverage to Codecov
|
|
uses: codecov/codecov-action@ab904c41d6ece82784817410c45d8b8c02684457 # v3
|
|
env:
|
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|