1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2024-12-15 17:51:20 +00:00

Merge pull request #2512 from realshuting/mutate_foreach_autogen

Add delay in e2e tests
This commit is contained in:
Pooja Singh 2021-10-11 15:47:49 +05:30 committed by GitHub
commit 7fbed3718f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1051,6 +1051,8 @@ func Test_Generate_Policy_Deletion_for_Clone(t *testing.T) {
err = commonE2E.PolicyCreated(tests.PolicyName) err = commonE2E.PolicyCreated(tests.PolicyName)
Expect(err).NotTo(HaveOccurred()) Expect(err).NotTo(HaveOccurred())
time.Sleep(5 * time.Second)
// ======= Create Namespace ================== // ======= Create Namespace ==================
By(fmt.Sprintf("Creating Namespace which triggers generate %s", clPolNS)) By(fmt.Sprintf("Creating Namespace which triggers generate %s", clPolNS))
_, err = e2eClient.CreateClusteredResourceYaml(nsGVR, namespaceYaml) _, 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 // test: generated resource is not deleted after deletion of generate policy
// ========== Delete the Generate Policy ============= // ========== Delete the Generate Policy =============
time.Sleep(2 * time.Second)
By(fmt.Sprintf("Delete the generate policy : %s", tests.PolicyName)) By(fmt.Sprintf("Delete the generate policy : %s", tests.PolicyName))
err = e2eClient.DeleteClusteredResource(clPolGVR, tests.PolicyName) err = e2eClient.DeleteClusteredResource(clPolGVR, tests.PolicyName)