Repository navigation
Commit 293a780
committed
build(opensearch-operator): run the tests of the packages the patches touch
The image build ran go test on two package trees listed by hand, and go
build never compiles a _test.go. A patch that reaches a directory
nobody listed brings tests that are proven once, by hand, when the
patch is cut, and nothing notices them failing after the next version
bump.
Run go test in the builder stage on the packages the patches touch. The
list is read from the patches themselves, so a new patch is covered
without an edit to the Dockerfile. It replaces the hand-picked go test
line, keeping its -race flag: two lines testing the same packages is
one too many. The hand-picked line also covered pkg/reconcilers/util,
which no patch touches.
controllers/ is left out. The stall-tracing patch touches it, and its
suite starts an envtest control plane from etcd and kube-apiserver
binaries the builder does not have, so testing it fails the build.
Assisted-by: LLM
Signed-off-by: Aleksei Sviridkin <[email protected]>1 parent bf03c84 commit 293a780
1 file changed
Lines changed: 14 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
87 | 89 | | |
88 | 90 | | |
89 | 91 | | |
90 | | - | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
91 | 98 | | |
92 | 99 | | |
93 | 100 | | |
| |||
0 commit comments