1
0
mirror of https://github.com/StackExchange/dnscontrol.git synced 2024-05-11 05:55:12 +00:00

DIGITALOCEAN: CAA is supported with some caveats (#592)

Change the tests to skip test case with CAA `;` value for Digitalocean,
because that specific feature isn't supported.

Closes #588
This commit is contained in:
Juho Teperi
2020-01-24 19:21:01 +02:00
committed by Tom Limoncelli
parent d3dc5a5eb7
commit bfa36ebbf8
3 changed files with 26 additions and 1 deletions

View File

@ -493,12 +493,19 @@ func makeTests(t *testing.T) []*TestCase {
if !providers.ProviderHasCapability(*providerToRun, providers.CanUseCAA) {
t.Log("Skipping CAA Tests because provider does not support them")
} else {
manyRecordsTc := tc("CAA many records", caa("@", "issue", 0, "letsencrypt.org"), caa("@", "issuewild", 0, ";"), caa("@", "iodef", 128, "mailto:test@example.com"))
// Digitalocean doesn't support ";" as value for CAA records
if *providerToRun == "DIGITALOCEAN" {
manyRecordsTc = tc("CAA many records", caa("@", "issue", 0, "letsencrypt.org"), caa("@", "issuewild", 0, "comodoca.com"), caa("@", "iodef", 128, "mailto:test@example.com"))
}
tests = append(tests, tc("Empty"),
tc("CAA record", caa("@", "issue", 0, "letsencrypt.org")),
tc("CAA change tag", caa("@", "issuewild", 0, "letsencrypt.org")),
tc("CAA change target", caa("@", "issuewild", 0, "example.com")),
tc("CAA change flag", caa("@", "issuewild", 128, "example.com")),
tc("CAA many records", caa("@", "issue", 0, "letsencrypt.org"), caa("@", "issuewild", 0, ";"), caa("@", "iodef", 128, "mailto:test@example.com")),
manyRecordsTc,
tc("CAA delete", caa("@", "issue", 0, "letsencrypt.org")),
)
}