Commit 4d23895
committed
envtest: disable controller metrics in tests
to mitigate spurious errors with:
E0515 15:28:06.626887 1995892 listener.go:48] "controller-runtime/metrics:
metrics server failed to listen. You may want to disable the metrics
server or use another port if it is due to conflicts" err="error lis
tening on :8080: listen tcp :8080: bind: address already in use"
disable metrics completely. Moreover, check for error value from
NewManager() before proceeding with the tests to avoid crashes.
This makes envtest more robust but the up()/down() logic needs
careful review to ensure there are no race conditions.
Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>1 parent d90aeda commit 4d23895
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
60 | 59 | | |
61 | 60 | | |
62 | 61 | | |
| |||
108 | 107 | | |
109 | 108 | | |
110 | 109 | | |
111 | | - | |
| 110 | + | |
| 111 | + | |
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
| |||
0 commit comments