-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f6c70fb
commit dd1f027
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Go test workflow | ||
on: [push] | ||
# | ||
env: | ||
APP_ENV: runner | ||
# Setting an environment variable with the value of a configuration variable | ||
CLIENT_KEY: ${{ secrets.CLIENT_KEY }} | ||
# Setting an environment variable with the value of a configuration variable | ||
CLIENT_SECRET: ${{ secrets.CLIENT_SECRET }} | ||
# | ||
# | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
go-version: [ '1.19.x', '1.20.x', '1.21.x', '1.22.x' ] | ||
# | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup Go ${{ matrix.go-version }} | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: ${{ matrix.go-version }} | ||
cache: true | ||
#cache-dependency-path: subdir/go.sum | ||
# | ||
# You can test your matrix by printing the current Go version | ||
- name: Display Go version | ||
run: go version | ||
# | ||
- name: Install dependencies | ||
run: go mod tidy | ||
# | ||
- name: Build | ||
run: go build -v ./... | ||
# | ||
- name: Test with the Go CLI | ||
run: go test -v ./... | ||
# | ||
# | ||
# |