Skip to content

Commit

Permalink
ci: run tests
Browse files Browse the repository at this point in the history
Runs tests (`go test`) in CI and enables codecov
  • Loading branch information
jaredallard committed Dec 21, 2023
1 parent 122f951 commit 82ebd63
Showing 1 changed file with 21 additions and 3 deletions.
24 changes: 21 additions & 3 deletions .github/workflows/golangci-lint.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: golangci-lint
name: tests
on:
push:
branches:
Expand All @@ -9,8 +9,26 @@ permissions:
contents: read

jobs:
golangci:
name: lint
gotest:
name: go test
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
- uses: jdx/rtx-action@v1
env:
GH_TOKEN: ${{ github.token }}
- name: Run go test
run: |
go run gotest.tools/gotestsum@latest -- -coverprofile=cover.out ./...
- name: Upload test coverage
uses: codecov/codecov-action@v4.0.0-beta.3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./cover.out
fail_ci_if_error: true

golangci-lint:
name: golangci-lint
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
Expand Down

0 comments on commit 82ebd63

Please sign in to comment.