Update myip.go #2
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: Run Tests | |
on: | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- ".github/workflows/agent.yml" | |
- ".github/workflows/codeql-analysis.yml" | |
- ".github/workflows/test-on-pr.yml" | |
- ".github/workflows/contributors.yml" | |
- "README.md" | |
- ".goreleaser.yml" | |
pull_request: | |
branches: | |
- main | |
jobs: | |
tests: | |
strategy: | |
fail-fast: true | |
matrix: | |
os: [ubuntu, windows, macos] | |
runs-on: ${{ matrix.os }}-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: "1.20.14" | |
- name: Unit test | |
# Skip TestCloudflareDetection here, as most IP addresses of Github's action | |
# runners have been marked as bot. | |
run: | | |
go test -skip TestCloudflareDetection -v ./... | |
#- name: Run Gosec Security Scanner | |
# if: runner.os == 'Linux' | |
# run: | | |
# go install github.com/securego/gosec/v2/cmd/[email protected] | |
# gosec -exclude=G104 ./... |