Use validateStartWithProxy to avoid network access failure
parent
2f052eb34a
commit
97ca925a8a
|
@ -61,14 +61,14 @@ func TestTunnel(t *testing.T) {
|
||||||
name string
|
name string
|
||||||
validator validateFunc
|
validator validateFunc
|
||||||
}{
|
}{
|
||||||
{"Start", validateMinikubeStart},
|
{"StartWithProxy", validateStartWithProxy}, // Start cluster same as TestFunctional
|
||||||
{"StartTunnel", validateTunnelStart},
|
{"StartTunnel", validateTunnelStart}, // Start tunnel
|
||||||
{"WaitService", validateServiceStable},
|
{"WaitService", validateServiceStable}, // Wait for service is stable
|
||||||
{"AccessDirect", validateAccessDirect},
|
{"AccessDirect", validateAccessDirect}, // Access test for loadbalancer IP
|
||||||
{"DNSResolutionByDig", validateDNSDig},
|
{"DNSResolutionByDig", validateDNSDig}, // DNS forwarding test by dig
|
||||||
{"DNSResolutionByDscacheutil", validateDNSDscacheutil},
|
{"DNSResolutionByDscacheutil", validateDNSDscacheutil}, // DNS forwarding test by dscacheutil
|
||||||
{"AccessThroughDNS", validateAccessDNS},
|
{"AccessThroughDNS", validateAccessDNS}, // Access test for absolute dns name
|
||||||
{"DeleteTunnel", validateTunnelDelete},
|
{"DeleteTunnel", validateTunnelDelete}, // Stop tunnel and delete cluster
|
||||||
}
|
}
|
||||||
for _, tc := range tests {
|
for _, tc := range tests {
|
||||||
tc := tc
|
tc := tc
|
||||||
|
@ -117,17 +117,6 @@ func getKubeDNSIP(t *testing.T, profile string) string {
|
||||||
return ip.String()
|
return ip.String()
|
||||||
}
|
}
|
||||||
|
|
||||||
// validateMinikubeStart starts minikube cluster
|
|
||||||
func validateMinikubeStart(ctx context.Context, t *testing.T, profile string) {
|
|
||||||
checkRoutePassword(t)
|
|
||||||
|
|
||||||
args := append([]string{"start", "-p", profile, "--memory=1800", "--install-addons=false", "--wait=all"}, StartArgs()...)
|
|
||||||
rr, err := Run(t, exec.CommandContext(ctx, Target(), args...))
|
|
||||||
if err != nil {
|
|
||||||
t.Fatalf("failed to start minikube with args: %q : %v", rr.Command(), err)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// validateTunnelStart starts `minikube tunnel`
|
// validateTunnelStart starts `minikube tunnel`
|
||||||
func validateTunnelStart(ctx context.Context, t *testing.T, profile string) {
|
func validateTunnelStart(ctx context.Context, t *testing.T, profile string) {
|
||||||
checkRoutePassword(t)
|
checkRoutePassword(t)
|
||||||
|
|
Loading…
Reference in New Issue