Skip to content

Merge pull request #108 from grafana/107-use-go-1.23.3-in-github-acti… #135

Merge pull request #108 from grafana/107-use-go-1.23.3-in-github-acti…

Merge pull request #108 from grafana/107-use-go-1.23.3-in-github-acti… #135

Workflow file for this run

name: test
on:
pull_request:
branches:
- main
workflow_dispatch:
push:
branches:
- main
paths-ignore:
- "docs/**"
- README.md
- "releases/**"
jobs:
test:
name: Test
strategy:
matrix:
platform:
- ubuntu-latest
- macos-latest
- windows-latest
runs-on: ${{matrix.platform}}
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: "1.22.2"
- name: Checkout code
uses: actions/checkout@v4
- name: Test
run: go test -race -count 1 ./...
- name: Coverage Test
if: ${{ matrix.platform == 'ubuntu-latest' && github.ref_name == 'main' }}
run: go test -count 1 -coverprofile=coverage.txt ./...
- name: Upload Coverage
if: ${{ matrix.platform == 'ubuntu-latest' && github.ref_name == 'main' }}
uses: codecov/codecov-action@v4.6.0
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: grafana/k6exec
- name: Generate Go Report Card
if: ${{ matrix.platform == 'ubuntu-latest' && github.ref_name == 'main' }}
uses: creekorful/goreportcard-action@v1.0