ci: broaden test workflow to run the full go test ./... suite - #3
Merged
Conversation
The workflow previously ran only ./pkg/... and a single -run TestNextSourceBranches in ./controllers, missing the new api/v1alpha1 tests and the other controllers tests (store-decision, label-folding, churn-guard, reconcile fake-client paths). Switch the test step to go test ./... -v. Safe without envtest: the controllers tests use the controller-runtime fake client and the Ginkgo TestAPIs suite has no specs (passes trivially without KUBEBUILDER_ASSETS). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Broadens the existing
.github/workflows/test.ymltest step to run the whole suite.build.ymlis untouched.Before:
After:
(
go build ./...unchanged; Go pinned at 1.19 pergo.mod.)Why
The narrow test step missed the newly-added
api/v1alpha1tests and most of thecontrollerstests (store-decision, label-folding, churn-guard, reconcile fake-client paths). Broadening to./...makes those gate future PRs.Safe without envtest: the new controllers tests use the controller-runtime fake client, and the Ginkgo
TestAPIssuite has no specs (runs 0 of 0 → SUCCESS) so it passes trivially withoutKUBEBUILDER_ASSETS. The stale comment claiming the controllers suite needs envtest is replaced.Local verification
In a clean worktree (Go 1.25 locally; the workflow pins 1.19):
go build ./...→ OKgo test ./... -v→ green end-to-end, 0 failures.api/v1alpha1(4 funcs),controllers(7 funcs incl. the 0-specTestAPIs),pkg/git(5 funcs) allok.test.ymlparses as valid YAML.🤖 Generated with Claude Code