merge PR from dev/core #15
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: PR Test | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
paths: | |
- '**/*.go' | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-go@v3 | |
with: | |
go-version: '>=1.19.3' | |
- uses: golangci/[email protected] | |
with: | |
version: latest | |
test: | |
runs-on: ubuntu-latest | |
needs: [lint] | |
steps: | |
- name: ✨ Checkout repository | |
uses: actions/checkout@v3 | |
- name: 💻 Set up Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: '>=1.19.3' | |
- name: 📥 Install dependencies | |
run: go get ./... | |
- name: 📝 Check code style | |
run: gofmt -d -s -w . | |
- run: go mod tidy | |
- run: go clean ./... | |
- name: 🔬 Test Go with coverage | |
run: go test -coverprofile=coverage.out ./... ; go tool cover -func=coverage.out |