|
| 1 | +name: Nightly tests |
| 2 | + |
| 3 | +on: |
| 4 | + schedule: |
| 5 | + - cron: "0 6 * * *" # 6am UTC, daily. |
| 6 | + workflow_dispatch: |
| 7 | + |
| 8 | +jobs: |
| 9 | + |
| 10 | + linux: |
| 11 | + name: linux |
| 12 | + strategy: |
| 13 | + matrix: |
| 14 | + go: [ '1.22', '1.23' ] |
| 15 | + runs-on: ubuntu-latest |
| 16 | + steps: |
| 17 | + - uses: actions/checkout@v4 |
| 18 | + |
| 19 | + - name: Set up Go |
| 20 | + uses: actions/setup-go@v4 |
| 21 | + with: |
| 22 | + go-version: ${{ matrix.go }} |
| 23 | + |
| 24 | + - run: GOTRACEBACK=all make test testobjiotracing generate |
| 25 | + |
| 26 | + - name: Assert workspace clean |
| 27 | + run: scripts/check-workspace-clean.sh |
| 28 | + |
| 29 | + - name: Post issue on failure |
| 30 | + if: failure() |
| 31 | + id: create-or-update-unique-issue |
| 32 | + uses: ./.github/actions/post-issue |
| 33 | + with: |
| 34 | + title: "nightly test failed" |
| 35 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 36 | + unique-title-includes: "nightly test failed" |
| 37 | + labels: "C-test-failure" |
| 38 | + |
| 39 | + |
| 40 | + linux-32bit: |
| 41 | + name: linux-32bit |
| 42 | + strategy: |
| 43 | + matrix: |
| 44 | + go: [ '1.22', '1.23' ] |
| 45 | + runs-on: ubuntu-latest |
| 46 | + steps: |
| 47 | + - uses: actions/checkout@v4 |
| 48 | + |
| 49 | + - name: Set up Go |
| 50 | + uses: actions/setup-go@v4 |
| 51 | + with: |
| 52 | + go-version: ${{ matrix.go }} |
| 53 | + |
| 54 | + - run: GOTRACEBACK=all GOARCH=386 make test |
| 55 | + |
| 56 | + - name: Post issue on failure |
| 57 | + if: failure() |
| 58 | + id: create-or-update-unique-issue |
| 59 | + uses: ./.github/actions/post-issue |
| 60 | + with: |
| 61 | + title: "nightly test failed" |
| 62 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 63 | + unique-title-includes: "nightly test failed" |
| 64 | + labels: "C-test-failure" |
| 65 | + |
| 66 | + |
| 67 | + linux-arm: |
| 68 | + name: linux-arm |
| 69 | + strategy: |
| 70 | + matrix: |
| 71 | + go: [ '1.22', '1.23' ] |
| 72 | + runs-on: ubuntu-22.04-arm |
| 73 | + steps: |
| 74 | + - uses: actions/checkout@v4 |
| 75 | + |
| 76 | + - name: Set up Go |
| 77 | + uses: actions/setup-go@v4 |
| 78 | + with: |
| 79 | + go-version: ${{ matrix.go }} |
| 80 | + |
| 81 | + - run: GOTRACEBACK=all make test |
| 82 | + |
| 83 | + - name: Post issue on failure |
| 84 | + if: failure() |
| 85 | + id: create-or-update-unique-issue |
| 86 | + uses: ./.github/actions/post-issue |
| 87 | + with: |
| 88 | + title: "nightly test failed" |
| 89 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 90 | + unique-title-includes: "nightly test failed" |
| 91 | + labels: "C-test-failure" |
| 92 | + |
| 93 | + |
| 94 | + linux-crossversion: |
| 95 | + name: linux-crossversion |
| 96 | + strategy: |
| 97 | + matrix: |
| 98 | + go: [ '1.22', '1.23' ] |
| 99 | + runs-on: ubuntu-latest |
| 100 | + steps: |
| 101 | + - uses: actions/checkout@v4 |
| 102 | + with: |
| 103 | + # This target needs to find the crl-release-* branches. |
| 104 | + fetch-depth: 0 |
| 105 | + |
| 106 | + - name: Set up Go |
| 107 | + uses: actions/setup-go@v4 |
| 108 | + with: |
| 109 | + go-version: ${{ matrix.go }} |
| 110 | + |
| 111 | + - run: make crossversion-meta |
| 112 | + |
| 113 | + - name: Post issue on failure |
| 114 | + if: failure() |
| 115 | + id: create-or-update-unique-issue |
| 116 | + uses: ./.github/actions/post-issue |
| 117 | + with: |
| 118 | + title: "nightly test failed" |
| 119 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 120 | + unique-title-includes: "nightly test failed" |
| 121 | + labels: "C-test-failure" |
| 122 | + |
| 123 | + |
| 124 | + linux-no-invariants: |
| 125 | + name: linux-no-invariants |
| 126 | + strategy: |
| 127 | + matrix: |
| 128 | + go: [ '1.22', '1.23' ] |
| 129 | + runs-on: ubuntu-latest |
| 130 | + steps: |
| 131 | + - uses: actions/checkout@v4 |
| 132 | + |
| 133 | + - name: Set up Go |
| 134 | + uses: actions/setup-go@v4 |
| 135 | + with: |
| 136 | + go-version: ${{ matrix.go }} |
| 137 | + |
| 138 | + - run: GOTRACEBACK=all make test TAGS= |
| 139 | + |
| 140 | + - name: Post issue on failure |
| 141 | + if: failure() |
| 142 | + id: create-or-update-unique-issue |
| 143 | + uses: ./.github/actions/post-issue |
| 144 | + with: |
| 145 | + title: "nightly test failed" |
| 146 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 147 | + unique-title-includes: "nightly test failed" |
| 148 | + labels: "C-test-failure" |
| 149 | + |
| 150 | + |
| 151 | + linux-no-cgo: |
| 152 | + name: linux-no-cgo |
| 153 | + strategy: |
| 154 | + matrix: |
| 155 | + go: [ '1.22', '1.23' ] |
| 156 | + runs-on: ubuntu-latest |
| 157 | + steps: |
| 158 | + - uses: actions/checkout@v4 |
| 159 | + |
| 160 | + - name: Set up Go |
| 161 | + uses: actions/setup-go@v4 |
| 162 | + with: |
| 163 | + go-version: ${{ matrix.go }} |
| 164 | + |
| 165 | + - run: GOTRACEBACK=all CGO_ENABLED=0 make test TAGS= |
| 166 | + |
| 167 | + - name: Post issue on failure |
| 168 | + if: failure() |
| 169 | + id: create-or-update-unique-issue |
| 170 | + uses: ./.github/actions/post-issue |
| 171 | + with: |
| 172 | + title: "nightly test failed" |
| 173 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 174 | + unique-title-includes: "nightly test failed" |
| 175 | + labels: "C-test-failure" |
| 176 | + |
| 177 | + |
| 178 | + darwin: |
| 179 | + name: macos |
| 180 | + strategy: |
| 181 | + matrix: |
| 182 | + go: [ '1.22', '1.23' ] |
| 183 | + runs-on: macos-14 |
| 184 | + steps: |
| 185 | + - uses: actions/checkout@v4 |
| 186 | + |
| 187 | + - name: Set up Go |
| 188 | + uses: actions/setup-go@v4 |
| 189 | + with: |
| 190 | + go-version: ${{ matrix.go }} |
| 191 | + |
| 192 | + - run: GOTRACEBACK=all make test |
| 193 | + |
| 194 | + - name: Post issue on failure |
| 195 | + if: failure() |
| 196 | + id: create-or-update-unique-issue |
| 197 | + uses: ./.github/actions/post-issue |
| 198 | + with: |
| 199 | + title: "nightly test failed" |
| 200 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 201 | + unique-title-includes: "nightly test failed" |
| 202 | + labels: "C-test-failure" |
| 203 | + |
| 204 | + |
| 205 | + windows: |
| 206 | + name: windows |
| 207 | + strategy: |
| 208 | + matrix: |
| 209 | + go: [ '1.22', '1.23' ] |
| 210 | + runs-on: windows-latest |
| 211 | + steps: |
| 212 | + - uses: actions/checkout@v4 |
| 213 | + |
| 214 | + - name: Set up Go |
| 215 | + uses: actions/setup-go@v4 |
| 216 | + with: |
| 217 | + go-version: ${{ matrix.go }} |
| 218 | + |
| 219 | + - run: go test -tags invariants ./... |
| 220 | + |
| 221 | + - name: Post issue on failure |
| 222 | + if: failure() |
| 223 | + id: create-or-update-unique-issue |
| 224 | + uses: ./.github/actions/post-issue |
| 225 | + with: |
| 226 | + title: "nightly test failed" |
| 227 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 228 | + unique-title-includes: "nightly test failed" |
| 229 | + labels: "C-test-failure" |
| 230 | + |
| 231 | + lint-checks: |
| 232 | + name: lint-checks |
| 233 | + strategy: |
| 234 | + matrix: |
| 235 | + go: [ '1.22', '1.23' ] |
| 236 | + runs-on: ubuntu-latest |
| 237 | + steps: |
| 238 | + - uses: actions/checkout@v4 |
| 239 | + |
| 240 | + - name: Set up Go |
| 241 | + uses: actions/setup-go@v4 |
| 242 | + with: |
| 243 | + go-version: ${{ matrix.go }} |
| 244 | + |
| 245 | + - name: mod-tidy-check |
| 246 | + run: make mod-tidy-check |
| 247 | + |
| 248 | + - name: format-check |
| 249 | + run: make format-check |
| 250 | + |
| 251 | + - name: Post issue on failure |
| 252 | + if: failure() |
| 253 | + id: create-or-update-unique-issue |
| 254 | + uses: ./.github/actions/post-issue |
| 255 | + with: |
| 256 | + title: "nightly test failed" |
| 257 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 258 | + unique-title-includes: "nightly test failed" |
| 259 | + labels: "C-test-failure" |
| 260 | + |
| 261 | + |
| 262 | + # Builds for other architectures. |
| 263 | + build-other: |
| 264 | + name: build-other |
| 265 | + strategy: |
| 266 | + matrix: |
| 267 | + go: [ '1.22', '1.23' ] |
| 268 | + runs-on: ubuntu-latest |
| 269 | + steps: |
| 270 | + - uses: actions/checkout@v4 |
| 271 | + |
| 272 | + - name: Set up Go |
| 273 | + uses: actions/setup-go@v4 |
| 274 | + with: |
| 275 | + go-version: ${{ matrix.go }} |
| 276 | + |
| 277 | + - run: GOARCH=mips go build ./... |
| 278 | + - run: GOARCH=mipsle go build ./... |
| 279 | + - run: GOARCH=mips64le go build ./... |
| 280 | + - run: GOOS=freebsd go build -v ./... |
| 281 | + - run: GOOS=netbsd go build -v ./... |
| 282 | + - run: GOOS=openbsd go build -v ./... |
| 283 | + |
| 284 | + - name: Post issue on failure |
| 285 | + if: failure() |
| 286 | + id: create-or-update-unique-issue |
| 287 | + uses: ./.github/actions/post-issue |
| 288 | + with: |
| 289 | + title: "nightly test failed" |
| 290 | + body: "The nightly ${{ github.job_id }} test run failed on ${{ github.sha }}. Please review the run [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})." |
| 291 | + unique-title-includes: "nightly test failed" |
| 292 | + labels: "C-test-failure" |
0 commit comments