You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
val hostedZoneId = checkNotNull(createHostedZoneResp.hostedZone?.id) { "Hosted zone is unexpectedly null" }
27
+
val hostedZoneId = checkNotNull(createHostedZoneResp.hostedZone?.id) { "Hosted zone is unexpectedly null" }
25
28
26
-
val exception = assertFailsWith<InvalidChangeBatch> {
27
-
client.changeResourceRecordSets {
28
-
this.hostedZoneId = hostedZoneId
29
-
this.changeBatch =ChangeBatch {
30
-
this.changes =listOf(
31
-
Change {
32
-
this.action =ChangeAction.Delete
33
-
this.resourceRecordSet =ResourceRecordSet {
34
-
this.name ="test.blerg.com"
35
-
this.type =RrType.Cname
36
-
this.ttl =300
37
-
this.resourceRecords =listOf(
38
-
ResourceRecord {
39
-
value ="test.blerg.com"
40
-
}
41
-
)
42
-
}
43
-
},
44
-
Change {
45
-
this.action =ChangeAction.Create
46
-
this.resourceRecordSet =ResourceRecordSet {
47
-
this.name ="test.blerg.com"
48
-
this.type =RrType.Cname
49
-
this.ttl =300
50
-
this.resourceRecords =listOf(
51
-
ResourceRecord {
52
-
value ="test.blerg.com"
53
-
}
54
-
)
55
-
}
56
-
},
57
-
)
58
-
this.comment ="testing..."
29
+
val exception = assertFailsWith<InvalidChangeBatch> {
30
+
client.changeResourceRecordSets {
31
+
this.hostedZoneId = hostedZoneId
32
+
this.changeBatch =ChangeBatch {
33
+
this.changes =listOf(
34
+
Change {
35
+
this.action =ChangeAction.Delete
36
+
this.resourceRecordSet =ResourceRecordSet {
37
+
this.name ="test.blerg.com"
38
+
this.type =RrType.Cname
39
+
this.ttl =300
40
+
this.resourceRecords =listOf(
41
+
ResourceRecord {
42
+
value ="test.blerg.com"
43
+
},
44
+
)
45
+
}
46
+
},
47
+
Change {
48
+
this.action =ChangeAction.Create
49
+
this.resourceRecordSet =ResourceRecordSet {
50
+
this.name ="test.blerg.com"
51
+
this.type =RrType.Cname
52
+
this.ttl =300
53
+
this.resourceRecords =listOf(
54
+
ResourceRecord {
55
+
value ="test.blerg.com"
56
+
},
57
+
)
58
+
}
59
+
},
60
+
)
61
+
this.comment ="testing..."
62
+
}
59
63
}
60
64
}
61
-
}
62
65
63
-
client.deleteHostedZone {
64
-
id = hostedZoneId
65
-
}
66
+
client.deleteHostedZone {
67
+
id = hostedZoneId
68
+
}
66
69
67
-
assertNotNull(exception.message)
68
-
assertContains(exception.message, "[Tried to delete resource record set [name='test.blerg.com.', type='CNAME'] but it was not found, RRSet with DNS name test.blerg.com. is not permitted in zone this-is-a-test-domain-for-aws-sdk-kotlin.com., RRSet of type CNAME with DNS name test.blerg.com. is not permitted as it creates a CNAME loop in the zone.]")
69
-
} }
70
+
assertNotNull(exception.message)
71
+
assertContains(exception.message, "[Tried to delete resource record set [name='test.blerg.com.', type='CNAME'] but it was not found, RRSet with DNS name test.blerg.com. is not permitted in zone this-is-a-test-domain-for-aws-sdk-kotlin.com., RRSet of type CNAME with DNS name test.blerg.com. is not permitted as it creates a CNAME loop in the zone.]")
0 commit comments