* fix: Replace curl list backend with dbg command #9716 Signed-off-by: Son Bui <sonbv00@gmail.com> * fix: Remove curl dependencies in e2e tests #9716 Signed-off-by: Son Bui <sonbv00@gmail.com> --------- Signed-off-by: Son Bui <sonbv00@gmail.com>
This commit is contained in:
parent
53c2f2742f
commit
a92e7b4857
4 changed files with 25 additions and 31 deletions
|
|
@ -30,7 +30,6 @@ import (
|
|||
networking "k8s.io/api/networking/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
"k8s.io/ingress-nginx/internal/nginx"
|
||||
"k8s.io/ingress-nginx/test/e2e/framework"
|
||||
)
|
||||
|
||||
|
|
@ -330,17 +329,13 @@ var _ = framework.IngressNginxDescribe("[Service] Type ExternalName", func() {
|
|||
assert.Contains(ginkgo.GinkgoT(), body, `"X-Forwarded-Host": "echo"`)
|
||||
|
||||
ginkgo.By("checking the service is updated to use new host")
|
||||
curlCmd := fmt.Sprintf(
|
||||
"curl --fail --silent http://localhost:%v/configuration/backends",
|
||||
nginx.StatusPort,
|
||||
)
|
||||
|
||||
output, err := f.ExecIngressPod(curlCmd)
|
||||
dbgCmd := "/dbg backends all"
|
||||
output, err := f.ExecIngressPod(dbgCmd)
|
||||
assert.Nil(ginkgo.GinkgoT(), err)
|
||||
assert.Contains(
|
||||
ginkgo.GinkgoT(),
|
||||
output,
|
||||
fmt.Sprintf("{\"address\":\"%s\"", framework.BuildNIPHost(ip)),
|
||||
fmt.Sprintf(`"address": "%s"`, framework.BuildNIPHost(ip)),
|
||||
)
|
||||
})
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue