mirror of
https://github.com/k8sgpt-ai/k8sgpt.git
synced 2026-03-18 19:17:25 +00:00
Fixes #1610 The CI workflows were using inconsistent Go versions (1.22, 1.23) that didn't match go.mod (go 1.24.1, toolchain go1.24.11). This creates confusion for contributors and risks version-specific issues. Changes: - test.yaml: GO_VERSION ~1.22 -> ~1.24 - build_container.yaml: GO_VERSION ~1.23 -> ~1.24 - release.yaml: go-version 1.22 -> ~1.24 This aligns with PR #1609 which updates CONTRIBUTING.md to reflect go.mod's Go 1.24 requirement. Signed-off-by: Three Foxes (in a Trenchcoat) <threefoxes53235@gmail.com> Co-authored-by: Three Foxes (in a Trenchcoat) <threefoxes53235@gmail.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.24"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # 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@18283e04ce6e62d37312384ff67231eb8fd56d24 # v5
|
|
env:
|
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|