| 1 | name: "Continuous Integration" |
| 2 | |
| 3 | on: |
| 4 | workflow_dispatch: |
| 5 | push: |
| 6 | branches: [ main ] |
| 7 | paths: [ "*.go" ] |
| 8 | pull_request: |
| 9 | branches: [ main ] |
| 10 | paths: [ "*.go" ] |
| 11 | |
| 12 | jobs: |
| 13 | ci: |
| 14 | name: "Tests" |
| 15 | runs-on: ubuntu-latest |
| 16 | |
| 17 | env: |
| 18 | GOOS: "linux" |
| 19 | GOARCH: "amd64" |
| 20 | GO111MODULE: "on" |
| 21 | CGO_ENABLED: "0" |
| 22 | |
| 23 | steps: |
| 24 | - name: Set up Go |
| 25 | uses: actions/setup-go@v3 |
| 26 | with: |
| 27 | go-version: 1.21 |
| 28 | |
| 29 | - name: Check out go-incr |
| 30 | uses: actions/checkout@v3 |
| 31 | |
| 32 | - name: Run all tests |
| 33 | run: go test ./... |