https://github.com/cilium/cilium
Revision 9d4e99d500d0371bc5f42125d6c6772c387a7721 authored by Quentin Monnet on 23 June 2021, 14:25:47 UTC, committed by André Martins on 28 June 2021, 23:12:58 UTC
The AfterAll() and AfterEach() blocks in the test file for custom calls
run everytime, even if the Context block for the actual tests is
skipped. In that case, running the final blocks results in an attempt to
remove deployments that have never been set up in the first place. This
may lead to the blocks failing when the tests were in fact skipped, and
may produce test artifacts even though Jenkins does not considered the
test failed.

Let's reorganise those blocks, to make sure they are called only when
necessary. Note that we do need to keep both DeleteCilium() and
DeleteAll(), even if they are now in the same block, as calling only
DeleteAll() would not remove the Cilium ConfigMap.

Fixes: 37f6192c9e77 ("test: add CI test for tail calls hooks for custom programs")
Fixes: #13191
Fixes: #16633

Reported-by: Paul Chaignon <paul@cilium.io>
Signed-off-by: Quentin Monnet <quentin@isovalent.com>
1 parent d1a3b70
History
Tip revision: 9d4e99d500d0371bc5f42125d6c6772c387a7721 authored by Quentin Monnet on 23 June 2021, 14:25:47 UTC
tests: rework custom calls's AfterEach/AfterAll blocks to skip if needed
Tip revision: 9d4e99d

README.md

back to top