mirror of
https://github.com/k8sgpt-ai/k8sgpt.git
synced 2026-01-25 23:03:57 +00:00
* chore: missing schedule on auto merge Signed-off-by: Alex Jones <alexsimonjones@gmail.com> * feat: adding codecoverage back in Signed-off-by: Alex Jones <alexsimonjones@gmail.com> --------- Signed-off-by: Alex Jones <alexsimonjones@gmail.com>
31 lines
644 B
YAML
31 lines
644 B
YAML
name: Run tests
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
env:
|
|
GO_VERSION: "~1.21"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # 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@v3
|
|
env:
|
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|