@@ -215,6 +215,29 @@ func TestSetDefaultPublishingStrategySetsPlatformDefaults(t *testing.T) {
215215 }
216216 }
217217
218+ makeDefaultAWSPlatformStatus = func (platform configv1.PlatformType ) * configv1.PlatformStatus {
219+ return & configv1.PlatformStatus {
220+ Type : platform ,
221+ AWS : & configv1.AWSPlatformStatus {
222+ CloudLoadBalancerConfig : & configv1.CloudLoadBalancerConfig {
223+ DNSType : configv1 .PlatformDefaultDNSType ,
224+ },
225+ },
226+ }
227+ }
228+
229+ makeBYODNSAWSPlatformStatus = func (platform configv1.PlatformType ) * configv1.PlatformStatus {
230+ return & configv1.PlatformStatus {
231+ Type : platform ,
232+ AWS : & configv1.AWSPlatformStatus {
233+ CloudLoadBalancerConfig : & configv1.CloudLoadBalancerConfig {
234+ DNSType : configv1 .ClusterHostedDNSType ,
235+ ClusterHosted : & configv1.CloudLoadBalancerIPs {},
236+ },
237+ },
238+ }
239+ }
240+
218241 ingressConfigWithDefaultClassicLB = & configv1.Ingress {
219242 Spec : configv1.IngressSpec {
220243 LoadBalancer : configv1.LoadBalancer {
@@ -292,6 +315,18 @@ func TestSetDefaultPublishingStrategySetsPlatformDefaults(t *testing.T) {
292315 expectedIC : ingressControllerWithHostNetwork ,
293316 domainMatchesBaseDomain : true ,
294317 },
318+ {
319+ name : "AWS" ,
320+ platformStatus : makeDefaultAWSPlatformStatus (configv1 .AWSPlatformType ),
321+ expectedIC : ingressControllerWithLoadBalancer ,
322+ domainMatchesBaseDomain : true ,
323+ },
324+ {
325+ name : "AWS With BYO DNS" ,
326+ platformStatus : makeBYODNSAWSPlatformStatus (configv1 .AWSPlatformType ),
327+ expectedIC : ingressControllerWithLoadBalancerUnmanagedDNS ,
328+ domainMatchesBaseDomain : true ,
329+ },
295330 {
296331 name : "GCP" ,
297332 platformStatus : makeDefaultGCPPlatformStatus (configv1 .GCPPlatformType ),
0 commit comments