e2e: node: topomgr: avoid plugin leak on test fail

We need to make sure we tear down the sriov device plugin pod
should the tests fail, to avoid leaking pods in the test environment.

Signed-off-by: Francesco Romani <fromani@redhat.com>
This commit is contained in:
Francesco Romani 2020-09-04 18:23:31 +02:00
parent 6d01c5a589
commit 009b5356cb

View File

@ -527,6 +527,8 @@ func runTopologyManagerNodeAlignmentSuiteTests(f *framework.Framework, configMap
}
sd := setupSRIOVConfigOrFail(f, configMap)
defer teardownSRIOVConfigOrFail(f, sd)
envInfo := &testEnvInfo{
numaNodes: numaNodes,
sriovResourceName: sd.resourceName,
@ -695,7 +697,6 @@ func runTopologyManagerNodeAlignmentSuiteTests(f *framework.Framework, configMap
}
runTopologyManagerNegativeTest(f, 1, ctnAttrs, envInfo)
}
teardownSRIOVConfigOrFail(f, sd)
}
func runTopologyManagerTests(f *framework.Framework) {