@@ -3324,7 +3324,7 @@ func TestAWSProvider_adjustEndpointAndNewAaaaIfNeeded(t *testing.T) {
33243324 expectedAaaa : nil ,
33253325 },
33263326 {
3327- name : "MX record with alias=true should be treated as alias and not create AAAA" ,
3327+ name : "MX record with alias-related properties should drop them, keep ttl and not create AAAA" ,
33283328 ep : & endpoint.Endpoint {
33293329 DNSName : "test.foo.bar." ,
33303330 RecordType : endpoint .RecordTypeMX ,
@@ -3341,42 +3341,6 @@ func TestAWSProvider_adjustEndpointAndNewAaaaIfNeeded(t *testing.T) {
33413341 },
33423342 },
33433343 },
3344- expected : & endpoint.Endpoint {
3345- DNSName : "test.foo.bar." ,
3346- RecordType : endpoint .RecordTypeMX ,
3347- Targets : endpoint.Targets {"10 mail.example.com." },
3348- RecordTTL : 300 ,
3349- ProviderSpecific : endpoint.ProviderSpecific {
3350- {
3351- Name : providerSpecificAlias ,
3352- Value : "true" ,
3353- },
3354- {
3355- Name : providerSpecificEvaluateTargetHealth ,
3356- Value : "true" ,
3357- },
3358- },
3359- },
3360- expectedAaaa : nil ,
3361- },
3362- {
3363- name : "MX record with alias=false should drop alias properties and not create AAAA" ,
3364- ep : & endpoint.Endpoint {
3365- DNSName : "test.foo.bar." ,
3366- RecordType : endpoint .RecordTypeMX ,
3367- Targets : endpoint.Targets {"10 mail.example.com." },
3368- RecordTTL : 600 ,
3369- ProviderSpecific : endpoint.ProviderSpecific {
3370- {
3371- Name : providerSpecificAlias ,
3372- Value : "false" ,
3373- },
3374- {
3375- Name : providerSpecificEvaluateTargetHealth ,
3376- Value : "true" ,
3377- },
3378- },
3379- },
33803344 expected : & endpoint.Endpoint {
33813345 DNSName : "test.foo.bar." ,
33823346 RecordType : endpoint .RecordTypeMX ,
@@ -3386,33 +3350,6 @@ func TestAWSProvider_adjustEndpointAndNewAaaaIfNeeded(t *testing.T) {
33863350 },
33873351 expectedAaaa : nil ,
33883352 },
3389-
3390- // --- NS records ---
3391- {
3392- name : "NS record with alias=true should drop alias properties since NS does not support alias" ,
3393- ep : & endpoint.Endpoint {
3394- DNSName : "test.foo.bar." ,
3395- RecordType : endpoint .RecordTypeNS ,
3396- Targets : endpoint.Targets {"ns1.example.com." },
3397- ProviderSpecific : endpoint.ProviderSpecific {
3398- {
3399- Name : providerSpecificAlias ,
3400- Value : "true" ,
3401- },
3402- {
3403- Name : providerSpecificEvaluateTargetHealth ,
3404- Value : "true" ,
3405- },
3406- },
3407- },
3408- expected : & endpoint.Endpoint {
3409- DNSName : "test.foo.bar." ,
3410- RecordType : endpoint .RecordTypeNS ,
3411- Targets : endpoint.Targets {"ns1.example.com." },
3412- ProviderSpecific : endpoint.ProviderSpecific {},
3413- },
3414- expectedAaaa : nil ,
3415- },
34163353 }
34173354
34183355 for _ , tt := range tests {
0 commit comments