Skip to content

Commit bc941c8

Browse files
Merge pull request #9793 from jcpowermac/OCPBUGS-57535
OCPBUGS-57535: vSphere - remove unit tests using nip.io
2 parents 55b3518 + 343de76 commit bc941c8

File tree

1 file changed

+3
-47
lines changed

1 file changed

+3
-47
lines changed

pkg/asset/installconfig/vsphere/validation_test.go

Lines changed: 3 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@ const (
4141
tagTestAttachZoneOnHostsTags = 0x40
4242
)
4343

44-
const wildcardDNS = "nip.io"
45-
4644
func validIPIInstallConfig() *types.InstallConfig {
4745
return &types.InstallConfig{
4846
Networking: &types.Networking{
@@ -630,19 +628,7 @@ func Test_ensureDNS(t *testing.T) {
630628
name string
631629
installConfig *types.InstallConfig
632630
expectErr string
633-
}{
634-
{
635-
name: "valid dns",
636-
installConfig: func() *types.InstallConfig {
637-
installConfig := validIPIInstallConfig()
638-
installConfig.ObjectMeta.Name = "0a000803"
639-
installConfig.BaseDomain = wildcardDNS
640-
641-
return installConfig
642-
}(),
643-
expectErr: ``,
644-
},
645-
}
631+
}{}
646632
for _, test := range tests {
647633
t.Run(test.name, func(t *testing.T) {
648634
err := ensureDNS(test.installConfig, platformFieldPath, resolver).ToAggregate()
@@ -707,38 +693,8 @@ func Test_ensureLoadBalancer(t *testing.T) {
707693
stopTCPListen bool
708694
expectLevel string
709695
expectWarn string
710-
}{
711-
{
712-
name: "valid lb",
713-
installConfig: func() *types.InstallConfig {
714-
installConfig := validIPIInstallConfig()
715-
installConfig.ObjectMeta.Name = "7f000001"
716-
installConfig.BaseDomain = wildcardDNS
717-
installConfig.VSphere.APIVIPs = []string{}
718-
installConfig.VSphere.IngressVIPs = []string{}
719-
720-
return installConfig
721-
}(),
722-
stopTCPListen: false,
723-
expectLevel: ``,
724-
expectWarn: ``,
725-
},
726-
{
727-
name: "warn lb",
728-
installConfig: func() *types.InstallConfig {
729-
installConfig := validIPIInstallConfig()
730-
installConfig.ObjectMeta.Name = "7f000002"
731-
installConfig.BaseDomain = wildcardDNS
732-
installConfig.VSphere.APIVIPs = []string{}
733-
installConfig.VSphere.IngressVIPs = []string{}
734-
735-
return installConfig
736-
}(),
737-
stopTCPListen: true,
738-
expectLevel: `warning`,
739-
expectWarn: `Installation may fail, load balancer not available: dial tcp 127.0.0.2:6443: connect: connection refused`,
740-
},
741-
}
696+
}{}
697+
742698
for _, test := range tests {
743699
t.Run(test.name, func(t *testing.T) {
744700
if test.stopTCPListen {

0 commit comments

Comments
 (0)