Search in sources :

Example 1 with ProvisioningState

use of com.microsoft.azure.management.privatedns.v2018_09_01.ProvisioningState in project cloudbreak by hortonworks.

the class AzurePrivateDnsZoneValidatorServiceTest method testPrivateDnsZonesNotConnectedToNetworkWhenZoneProvisioningStateNotSucceeded.

@ParameterizedTest
@MethodSource(value = "getAllProvisioningStates")
void testPrivateDnsZonesNotConnectedToNetworkWhenZoneProvisioningStateNotSucceeded(ProvisioningState provisioningState) {
    ValidationResult.ValidationResultBuilder resultBuilder = ValidationResult.builder();
    PagedList<PrivateZone> privateDnsZoneList = getPrivateDnsZones(A_RESOURCE_GROUP_NAME, List.of(ZONE_NAME_POSTGRES), provisioningState);
    ValidationResult result = underTest.privateDnsZonesNotConnectedToNetwork(azureClient, NETWORK_NAME, SINGLE_RESOURCE_GROUP_NAME, ZONE_NAME_POSTGRES, resultBuilder, privateDnsZoneList);
    assertFalse(result.hasError());
    verify(azureClient, never()).getNetworkLinkByPrivateDnsZone(anyString(), anyString(), anyString());
}
Also used : ValidationResult(com.sequenceiq.cloudbreak.validation.ValidationResult) PrivateZone(com.microsoft.azure.management.privatedns.v2018_09_01.PrivateZone) ParameterizedTest(org.junit.jupiter.params.ParameterizedTest) MethodSource(org.junit.jupiter.params.provider.MethodSource)

Aggregations

PrivateZone (com.microsoft.azure.management.privatedns.v2018_09_01.PrivateZone)1 ValidationResult (com.sequenceiq.cloudbreak.validation.ValidationResult)1 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)1 MethodSource (org.junit.jupiter.params.provider.MethodSource)1