Commit 4f246fb
committed
test: fix missing mock nodes in conditionPolicy tests
The tests were failing in CI because anyOfNode was defined as a struct
but never created in the mock k8sClient. When the controller attempted
to remove/add taints on the node, the API server returned a 404 Not Found error.
Added Expect(k8sClient.Create(ctx, anyOfNode)).To(Succeed()) to the setup
of all tests in the ConditionPolicy Context.1 parent da613b6 commit 4f246fb
1 file changed
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2284 | 2284 | | |
2285 | 2285 | | |
2286 | 2286 | | |
| 2287 | + | |
| 2288 | + | |
2287 | 2289 | | |
2288 | 2290 | | |
2289 | 2291 | | |
| |||
2318 | 2320 | | |
2319 | 2321 | | |
2320 | 2322 | | |
| 2323 | + | |
| 2324 | + | |
2321 | 2325 | | |
2322 | 2326 | | |
2323 | 2327 | | |
| |||
2348 | 2352 | | |
2349 | 2353 | | |
2350 | 2354 | | |
| 2355 | + | |
| 2356 | + | |
2351 | 2357 | | |
2352 | 2358 | | |
2353 | 2359 | | |
| |||
2374 | 2380 | | |
2375 | 2381 | | |
2376 | 2382 | | |
| 2383 | + | |
| 2384 | + | |
2377 | 2385 | | |
2378 | 2386 | | |
2379 | 2387 | | |
| |||
0 commit comments