Repository navigation
ci: Run the test suite once, in the required check - #849
Merged
Merged
Conversation
CI (`ci / Build and test`, the required check) and Tests both ran the whole unit and envtest suite on every pull request. CI now also runs on pushes to release branches, as Tests did, and takes the concurrency group every other workflow has, so Tests goes. Its other steps already run elsewhere: Verify Generated Files fails on a generation diff, Lint runs go vet, gofmt and goimports, and CI builds the code. go mod tidy and go fmt rewrote files and never failed. Refs #837
scotwells
approved these changes
Nov 3, 2026
ecv
approved these changes
Nov 3, 2026
ecv
left a comment
Contributor
There was a problem hiding this comment.
Approve.
Deleting test.yml removes a second run of the same suite: ci.yaml's ci / Build and test already runs the unit and envtest packages (go test $(go list ./... | grep -v /e2e) -timeout 25m under setup-envtest), and it is the only check the required-ci ruleset requires, so no required check disappears. The 26-minute duplicate goes, and both checks passed at the head.
ci.yamlgainsrelease/**pushes and the same cancel-in-progress concurrencytest.ymlhad, so release branches keep their test run.make testalso ranmanifests generate fmt vet. Generated files are still covered byVerify Generated Files, andvetandfmtby the lint workflow, so nothing that gated before stops gating.
Follow-ups:
ci.yamlpins envtest to Kubernetes 1.31.0 whilemake testusesENVTEST_K8S_VERSION; keep the two in step, or have CI call the Makefile target.
Contributor
Author
|
Thanks, ecv. Agreed, and the two copies have already drifted: the Makefile installs setup-envtest from |
This was referenced Nov 3, 2026
vvoytovych
added a commit
to milo-os/milo
that referenced
this pull request
Nov 3, 2026
Related to #978. The required check, `ci / Build and test`, runs `go test ./...` with envtest 1.37.0 on every pull request and on `main`. "IAM API testing" ran the same `go test ./...` on every push that changed Go files. It is not required, so it gated nothing, and each pull request ran the suite twice. It goes, as [datum-cloud/network-services-operator#849](datum-cloud/network-services-operator#849) did for NSO, and CI takes the concurrency group the other workflows share. ## Where each step of IAM API testing runs now | step | where | |---|---| | `go mod download` | CI: `go test` downloads what it needs | | envtest 1.37.0 | CI: `setup-envtest use 1.37.0`, pinned by commit | | `go test ./...` | CI, with a 10 min timeout instead of 5 | ## Corner cases | case | what happens | |---|---| | A push to a branch with no pull request | No suite run until its pull request opens. Milo has no release branches; it releases by tag from `main`. | | A newer push to a pull request | The older CI run is cancelled. | | A push to `main` | Its run is never cancelled: `cancel-in-progress` is false on the default branch. | ## Test plan - [x] `ci / Build and test` ran the suite on #978's pull request and on this one: the quota controller package's envtests took [51.7 s](https://github.com/milo-os/milo/actions/runs/41592340528) and [52.3 s](https://github.com/milo-os/milo/actions/runs/41706707445/job/126163821686). - [x] `actionlint` passes on `ci.yaml`. The concurrency group is the one in `fix-newlines.yaml`, `test-environment-validation.yaml` and `test-prometheus-rules.yaml`, word for word. - [x] Nothing in the repository names `testing.yaml` or "IAM API testing". - [ ] After the merge: the push to `main` runs CI's suite, and "IAM API testing" no longer runs.
This was referenced Nov 4, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The required check,
ci / Build and test, and the Tests workflow both run the whole unit and envtest suite on every pull request, so each pull request runs it twice (#837). CI now also runs on pushes torelease/**, as Tests does, and takes the concurrency group that the other workflows share, so Tests goes. Every other step of Tests already runs in another check, or checks nothing.make teststays for local use.Where each step of Tests runs now
make manifests generatego vet,go fmtgovet,gofmtandgoimportsgo build ./...go mod tidy,go fmtas a step-coverprofile cover.outCorner cases
release/v0.34's last pushmainor a release branchci / Build and testTest plan
actionlintpasses on every workflow, and nothing else in the repository namestest.ymlor the Tests workflow.Refs #837