fix test for all properties
This commit is contained in:
parent
105bd2313c
commit
977bd595d8
@ -72,12 +72,30 @@ class HsDomainDnsSetupHostingAssetValidatorUnitTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void containsNoProperties() {
|
void containsExpectedProperties() {
|
||||||
// when
|
// when
|
||||||
final var validator = HsHostingAssetEntityValidatorRegistry.forType(CLOUD_SERVER);
|
final var validator = HsHostingAssetEntityValidatorRegistry.forType(DOMAIN_DNS_SETUP);
|
||||||
|
|
||||||
// then
|
// then
|
||||||
assertThat(validator.properties()).map(Map::toString).isEmpty();
|
assertThat(validator.properties()).map(Map::toString).containsExactlyInAnyOrder(
|
||||||
|
"{type=integer, propertyName=TTL, min=0, defaultValue=21600}",
|
||||||
|
"{type=boolean, propertyName=auto-SOA-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-NS-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-MX-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-A-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-AAAA-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-MAILSERVICES-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-AUTOCONFIG-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-AUTODISCOVER-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-DKIM-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-SPF-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-WILDCARD-MX-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-WILDCARD-A-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-WILDCARD-AAAA-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-WILDCARD-DKIM-RR, defaultValue=true}",
|
||||||
|
"{type=boolean, propertyName=auto-WILDCARD-SPF-RR, defaultValue=true}",
|
||||||
|
"{type=string[], propertyName=user-RR, elementsOf={type=string, propertyName=user-RR, matchesRegEx=[([a-z0-9\\.-]+|@)\\s+(([1-9][0-9]*[mMhHdDwW]{0,1})+\\s+)*IN\\s+[A-Z]+\\s+([a-z0-9\\.-]+|\\([^\\)]*\\)|\"[^\"]*\")\\s*(;.*)*, ([a-z0-9\\.-]+|@)\\s+IN\\s+(([1-9][0-9]*[mMhHdDwW]{0,1})+\\s+)*[A-Z]+\\s+([a-z0-9\\.-]+|\\([^\\)]*\\)|\"[^\"]*\")\\s*(;.*)*], required=true}}"
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
Loading…
Reference in New Issue
Block a user