use of com.sequenceiq.cloudbreak.api.endpoint.v4.common.FeatureState in project cloudbreak by hortonworks.
the class InternalClusterTemplateValidatorTest method internalClusterTemplateValidatorDataWithDefaultClusterTemplateV4RequestObject.
@ParameterizedTest(name = "state = {0} internalTenant = {1} expectedShouldPopulate = {2}")
@MethodSource("internalClusterTemplateValidatorData")
public void internalClusterTemplateValidatorDataWithDefaultClusterTemplateV4RequestObject(FeatureState state, boolean internalTenant, boolean expectedShouldPopulate) {
DefaultClusterTemplateV4Request clusterTemplate = new DefaultClusterTemplateV4Request();
clusterTemplate.setFeatureState(state);
boolean shouldPopulate = underTest.shouldPopulate(clusterTemplate, internalTenant);
Assert.assertEquals(expectedShouldPopulate, shouldPopulate);
}
use of com.sequenceiq.cloudbreak.api.endpoint.v4.common.FeatureState in project cloudbreak by hortonworks.
the class FeatureStateConverterTest method testConvertToEntityAttributeWhenNotKnownIsReturnAsReleased.
@Test
public void testConvertToEntityAttributeWhenNotKnownIsReturnAsReleased() {
FeatureState featureState = featureStateConverter.convertToEntityAttribute("not-known");
Assert.assertEquals(FeatureState.RELEASED, featureState);
}
use of com.sequenceiq.cloudbreak.api.endpoint.v4.common.FeatureState in project cloudbreak by hortonworks.
the class FeatureStateConverterTest method testConvertToEntityAttributeWhenReleasedIsReturnAsReleased.
@Test
public void testConvertToEntityAttributeWhenReleasedIsReturnAsReleased() {
FeatureState featureState = featureStateConverter.convertToEntityAttribute("RELEASED");
Assert.assertEquals(FeatureState.RELEASED, featureState);
}
Aggregations