add test for TXT record when vercel

This commit is contained in:
Roman committed 2026-08-30 18:29:03 +01:00
1 parent 190ec8d207
commit 4d82df2e2f
1 file changed
+9
+9
View File
@@ -238,6 +238,15 @@ function validateRecordValues(t, data, file) {
const values = Array.isArray(value) ? value : [value];
values.forEach((record, idx) => {
t.true(typeof record === "string", `${file}: TXT record value should be a string at index ${idx}`);
if (record.startsWith("vc-domain-verify=")) {
const domainToken = record.split("vc-domain-verify=")[1].split(",")[0];
t.true(
domainToken.endsWith(".is-a.dev"),
`${file}: Vercel TXT verification must target a subdomain of is-a.dev`
);
}
});
}
});