mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-12-25 12:55:09 -07:00
feat: add Golang tests to GitHub test workflow
This commit is contained in:
parent
d8afc037c7
commit
3c876d25cd
2
.github/workflows/lint.yml
vendored
2
.github/workflows/lint.yml
vendored
@ -39,6 +39,8 @@ jobs:
|
|||||||
run: go install honnef.co/go/tools/cmd/staticcheck@latest
|
run: go install honnef.co/go/tools/cmd/staticcheck@latest
|
||||||
- name: Lint
|
- name: Lint
|
||||||
run: staticcheck -tests -show-ignored ./...
|
run: staticcheck -tests -show-ignored ./...
|
||||||
|
- name: Build
|
||||||
|
run: build -v ./...
|
||||||
|
|
||||||
actions:
|
actions:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
15
.github/workflows/tests.yml
vendored
15
.github/workflows/tests.yml
vendored
@ -35,6 +35,21 @@ jobs:
|
|||||||
- 'defaults'
|
- 'defaults'
|
||||||
- 'help.txt'
|
- 'help.txt'
|
||||||
|
|
||||||
|
test-golang:
|
||||||
|
needs: detect-changes
|
||||||
|
if: ${{ needs.detect-changes.outputs.cli == 'true' }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Setup Go
|
||||||
|
uses: actions/setup-go@v4
|
||||||
|
with:
|
||||||
|
go-version: '1.21.5'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: go get .
|
||||||
|
- name: Run Go tests
|
||||||
|
run: go test
|
||||||
|
|
||||||
ubuntu:
|
ubuntu:
|
||||||
needs: detect-changes
|
needs: detect-changes
|
||||||
# only run if
|
# only run if
|
||||||
|
Loading…
Reference in New Issue
Block a user