Revert test workflow changes (gopath is broken)

This commit is contained in:
bvanvugt 2023-02-20 00:31:41 +00:00
parent 4f4cd62a87
commit 839ea036c2

View file

@ -21,7 +21,8 @@ jobs:
with:
go-version: '${{ env.GO_VERSION }}'
check-latest: true
- run: make test-format
- name: Run gofmt
run: test -z $(gofmt -l .) || (gofmt -d . && exit 1)
lint:
name: Lint (golangci-lint)
@ -33,10 +34,13 @@ jobs:
with:
go-version: '${{ env.GO_VERSION }}'
check-latest: true
- run: make test-lint
- name: Run golangci-lint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.51.1
golangci-lint run -v ./...
test:
name: Tests (go test)
name: Test (go test)
runs-on: ubuntu-latest
needs: [lint]
steps:
@ -45,7 +49,8 @@ jobs:
with:
go-version: '${{ env.GO_VERSION }}'
check-latest: true
- run: make test-unit
- name: Run go test
run: go test -race ./...
build-cli:
name: Build CLI (go build)
@ -57,6 +62,7 @@ jobs:
with:
go-version: '${{ env.GO_VERSION }}'
check-latest: true
- run: |
make build-cli
battlesnake --help
- name: Run go build
run: |
go build ./cli/battlesnake
./battlesnake --help