From 6ea15783e9157be1417c6c8f53b6c15106670d63 Mon Sep 17 00:00:00 2001 From: gavinfish Date: Tue, 24 Mar 2020 11:44:09 +0800 Subject: [PATCH] Delete Cleanup method in e2e util --- test/e2e/framework/util.go | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/test/e2e/framework/util.go b/test/e2e/framework/util.go index aa4100ca013..1a20bc33277 100644 --- a/test/e2e/framework/util.go +++ b/test/e2e/framework/util.go @@ -553,17 +553,6 @@ func RandomSuffix() string { return strconv.Itoa(rand.Intn(10000)) } -// Cleanup stops everything from filePath from namespace ns and checks if everything matching selectors from the given namespace is correctly stopped. -func Cleanup(filePath, ns string, selectors ...string) { - ginkgo.By("using delete to clean up resources") - var nsArg string - if ns != "" { - nsArg = fmt.Sprintf("--namespace=%s", ns) - } - RunKubectlOrDie(ns, "delete", "--grace-period=0", "-f", filePath, nsArg) - AssertCleanup(ns, selectors...) -} - // AssertCleanup asserts that cleanup of a namespace wrt selectors occurred. func AssertCleanup(ns string, selectors ...string) { var nsArg string