From b5497f377c0fb07f8b78361c570b4f7ad0e6ef0b Mon Sep 17 00:00:00 2001 From: ShutingZhao Date: Sun, 10 Oct 2021 20:22:36 -0700 Subject: [PATCH] add delay in e2e test Signed-off-by: ShutingZhao --- test/e2e/generate/generate_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/e2e/generate/generate_test.go b/test/e2e/generate/generate_test.go index c2ad92b0e4..7d8c53bc14 100644 --- a/test/e2e/generate/generate_test.go +++ b/test/e2e/generate/generate_test.go @@ -1051,6 +1051,8 @@ func Test_Generate_Policy_Deletion_for_Clone(t *testing.T) { err = commonE2E.PolicyCreated(tests.PolicyName) Expect(err).NotTo(HaveOccurred()) + time.Sleep(5 * time.Second) + // ======= Create Namespace ================== By(fmt.Sprintf("Creating Namespace which triggers generate %s", clPolNS)) _, err = e2eClient.CreateClusteredResourceYaml(nsGVR, namespaceYaml) @@ -1081,6 +1083,7 @@ func Test_Generate_Policy_Deletion_for_Clone(t *testing.T) { // test: generated resource is not deleted after deletion of generate policy // ========== Delete the Generate Policy ============= + time.Sleep(2 * time.Second) By(fmt.Sprintf("Delete the generate policy : %s", tests.PolicyName)) err = e2eClient.DeleteClusteredResource(clPolGVR, tests.PolicyName)