Improve path rule (#8623)
* Improve path rule * Add nginx configuration tests * Revert framework changes * Add test to patched directives * Fix root conf test * Add comment in new function
This commit is contained in:
parent
4dfb3f2e9a
commit
bd1eb048b7
6 changed files with 210 additions and 19 deletions
|
|
@ -150,8 +150,9 @@ http {
|
|||
f.NGINXWithConfigDeployment(SlowEchoService, cfg)
|
||||
}
|
||||
|
||||
// NGINXWithConfigDeployment creates an NGINX deployment using a configmap containing the nginx.conf configuration
|
||||
func (f *Framework) NGINXWithConfigDeployment(name string, cfg string) {
|
||||
// NGINXDeployment creates a new simple NGINX Deployment using NGINX base image
|
||||
// and passing the desired configuration
|
||||
func (f *Framework) NGINXDeployment(name string, cfg string, waitendpoint bool) {
|
||||
cfgMap := map[string]string{
|
||||
"nginx.conf": cfg,
|
||||
}
|
||||
|
|
@ -213,8 +214,15 @@ func (f *Framework) NGINXWithConfigDeployment(name string, cfg string) {
|
|||
|
||||
f.EnsureService(service)
|
||||
|
||||
err = WaitForEndpoints(f.KubeClientSet, DefaultTimeout, name, f.Namespace, 1)
|
||||
assert.Nil(ginkgo.GinkgoT(), err, "waiting for endpoints to become ready")
|
||||
if waitendpoint {
|
||||
err = WaitForEndpoints(f.KubeClientSet, DefaultTimeout, name, f.Namespace, 1)
|
||||
assert.Nil(ginkgo.GinkgoT(), err, "waiting for endpoints to become ready")
|
||||
}
|
||||
}
|
||||
|
||||
// NGINXWithConfigDeployment creates an NGINX deployment using a configmap containing the nginx.conf configuration
|
||||
func (f *Framework) NGINXWithConfigDeployment(name string, cfg string) {
|
||||
f.NGINXDeployment(name, cfg, true)
|
||||
}
|
||||
|
||||
// NewGRPCBinDeployment creates a new deployment of the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue