Bump golang.org/x/oauth2 from 0.12.0 to 0.13.0 #473
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: Go | |
on: | |
push: | |
branches: master | |
pull_request: | |
branches: master | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Go 1.20 | |
uses: actions/setup-go@v3 | |
with: | |
go-version: '1.20' | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v3 | |
with: | |
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. | |
version: v1.51 | |
- name: Test | |
run: go test -v ./... | |
- name: Coverage | |
id: coverage | |
run: | | |
go test -v -coverpkg=./... -coverprofile=cov.out ./... | |
go tool cover -html=cov.out -o coverage.html | |
COV=$(go tool cover -func=cov.out | awk '/total/ { gsub("%", "", $3); print $3 }') | |
echo "Total coverage: ${COV} (Required ${MIN_COV})" | |
(( $(echo "${COV} > ${MIN_COV}" | bc -l) )) && echo "Min coverage passed" || exit 1 | |
env: | |
MIN_COV: 60 | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: coverage | |
path: coverage.html | |
retention-days: 7 |