Skip to content

Commit

Permalink
feat: support k8s native ingress and backend service in the different…
Browse files Browse the repository at this point in the history
… namespace
  • Loading branch information
shareinto committed Oct 27, 2022
1 parent e7b5beb commit 166b392
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/e2e/scaffold/scaffold.go
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,7 @@ func (s *Scaffold) beforeEach() {
}

k8s.CreateNamespaceWithMetadata(s.t, s.kubectlOptions, metav1.ObjectMeta{Name: s.namespace, Labels: label})
k8s.CreateNamespaceWithMetadata(s.t, s.kubectlOptions, metav1.ObjectMeta{Name: s.namespace + "-new", Labels: label})

s.nodes, err = k8s.GetReadyNodesE(s.t, s.kubectlOptions)
assert.Nil(s.t, err, "querying ready nodes")
Expand Down Expand Up @@ -489,11 +490,15 @@ func (s *Scaffold) afterEach() {
}
err := k8s.DeleteNamespaceE(s.t, s.kubectlOptions, s.namespace)
assert.Nilf(ginkgo.GinkgoT(), err, "deleting namespace %s", s.namespace)
err = k8s.DeleteNamespaceE(s.t, s.kubectlOptions, s.namespace+"-new")
assert.Nilf(ginkgo.GinkgoT(), err, "deleting namespace %s", s.namespace+"-new")
}
} else {
// if the test case is successful, just delete namespace
err := k8s.DeleteNamespaceE(s.t, s.kubectlOptions, s.namespace)
assert.Nilf(ginkgo.GinkgoT(), err, "deleting namespace %s", s.namespace)
err = k8s.DeleteNamespaceE(s.t, s.kubectlOptions, s.namespace+"-new")
assert.Nilf(ginkgo.GinkgoT(), err, "deleting namespace %s", s.namespace+"-new")
}

for _, f := range s.finializers {
Expand Down

0 comments on commit 166b392

Please sign in to comment.