Commit de8c024
committed
Fix deletion policy tests
The deletion policy was not being set at all for tests. Why? Because
BeforeEach nodes run BEFORE the JustBeforeEach. Therefore, the
BeforeEach was setting the deletion policy in the spec, and right after
the JustAfterEach in the top container was assigning a "zero" value for
the topology type. This effectively "overrode" the value set for
deletion policy.
This was probably passing because Create/Delete were called one after
the other, and sometimes the deletion behaviour simply skipped because
the object was not found, since it was "too soon" and not returned by
the informer cache.
These tests should have been rightfuly red. The were flaking to green.1 parent 342851f commit de8c024
File tree
4 files changed
+35
-15
lines changed- controllers
4 files changed
+35
-15
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
233 | 233 | | |
234 | 234 | | |
235 | 235 | | |
236 | | - | |
237 | 236 | | |
238 | 237 | | |
239 | 238 | | |
240 | 239 | | |
| 240 | + | |
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
| 244 | + | |
244 | 245 | | |
245 | | - | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
246 | 250 | | |
| 251 | + | |
247 | 252 | | |
248 | 253 | | |
249 | 254 | | |
250 | 255 | | |
251 | 256 | | |
252 | 257 | | |
253 | | - | |
| 258 | + | |
254 | 259 | | |
255 | | - | |
| 260 | + | |
256 | 261 | | |
257 | 262 | | |
258 | 263 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
229 | 229 | | |
230 | 230 | | |
231 | 231 | | |
232 | | - | |
233 | 232 | | |
234 | 233 | | |
235 | 234 | | |
236 | 235 | | |
237 | 236 | | |
238 | 237 | | |
239 | 238 | | |
| 239 | + | |
240 | 240 | | |
241 | | - | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
242 | 245 | | |
| 246 | + | |
243 | 247 | | |
244 | 248 | | |
245 | 249 | | |
246 | 250 | | |
247 | 251 | | |
248 | 252 | | |
249 | | - | |
| 253 | + | |
250 | 254 | | |
251 | | - | |
| 255 | + | |
252 | 256 | | |
253 | 257 | | |
254 | 258 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
290 | 290 | | |
291 | 291 | | |
292 | 292 | | |
| 293 | + | |
293 | 294 | | |
294 | 295 | | |
295 | 296 | | |
296 | | - | |
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
300 | 300 | | |
| 301 | + | |
301 | 302 | | |
302 | 303 | | |
303 | 304 | | |
| 305 | + | |
304 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
305 | 311 | | |
306 | 312 | | |
307 | 313 | | |
| |||
310 | 316 | | |
311 | 317 | | |
312 | 318 | | |
313 | | - | |
| 319 | + | |
314 | 320 | | |
315 | | - | |
| 321 | + | |
316 | 322 | | |
317 | 323 | | |
318 | 324 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
369 | 369 | | |
370 | 370 | | |
371 | 371 | | |
372 | | - | |
373 | 372 | | |
374 | 373 | | |
375 | 374 | | |
376 | 375 | | |
| 376 | + | |
377 | 377 | | |
378 | 378 | | |
379 | 379 | | |
| 380 | + | |
380 | 381 | | |
381 | | - | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
382 | 386 | | |
| 387 | + | |
383 | 388 | | |
384 | 389 | | |
385 | 390 | | |
386 | 391 | | |
387 | 392 | | |
388 | 393 | | |
389 | | - | |
| 394 | + | |
390 | 395 | | |
391 | | - | |
| 396 | + | |
392 | 397 | | |
393 | 398 | | |
394 | 399 | | |
0 commit comments