Search in sources :

Example 6 with TagResponse

use of com.sequenceiq.environment.api.v1.environment.model.response.TagResponse in project cloudbreak by hortonworks.

the class AllocateDatabaseServerV4RequestToDBStackConverterTest method setupMinimalValid.

private void setupMinimalValid(SslConfigV4Request sslConfigV4Request, CloudPlatform cloudPlatform) {
    allocateRequest.setEnvironmentCrn(ENVIRONMENT_CRN);
    allocateRequest.setTags(new HashMap<>());
    allocateRequest.setClusterCrn(CLUSTER_CRN);
    allocateRequest.setSslConfig(sslConfigV4Request);
    DetailedEnvironmentResponse environment = DetailedEnvironmentResponse.builder().withCloudPlatform(cloudPlatform.name()).withCrn(ENVIRONMENT_CRN).withLocation(LocationResponse.LocationResponseBuilder.aLocationResponse().withName(REGION).build()).withName(ENVIRONMENT_NAME).withTag(new TagResponse()).build();
    when(environmentService.getByCrn(ENVIRONMENT_CRN)).thenReturn(environment);
    databaseServerRequest.setDatabaseVendor(DATABASE_VENDOR);
}
Also used : TagResponse(com.sequenceiq.environment.api.v1.environment.model.response.TagResponse) DetailedEnvironmentResponse(com.sequenceiq.environment.api.v1.environment.model.response.DetailedEnvironmentResponse)

Aggregations

TagResponse (com.sequenceiq.environment.api.v1.environment.model.response.TagResponse)6 DetailedEnvironmentResponse (com.sequenceiq.environment.api.v1.environment.model.response.DetailedEnvironmentResponse)5 StackTags (com.sequenceiq.cloudbreak.cloud.model.StackTags)2 DBStack (com.sequenceiq.redbeams.domain.stack.DBStack)2 Test (org.junit.jupiter.api.Test)2 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)2 StackV4Request (com.sequenceiq.cloudbreak.api.endpoint.v4.stacks.request.StackV4Request)1 ClusterV4Request (com.sequenceiq.cloudbreak.api.endpoint.v4.stacks.request.cluster.ClusterV4Request)1 CloudSubnet (com.sequenceiq.cloudbreak.cloud.model.CloudSubnet)1 Stack (com.sequenceiq.cloudbreak.domain.stack.Stack)1 Cluster (com.sequenceiq.cloudbreak.domain.stack.cluster.Cluster)1 CDPTagMergeRequest (com.sequenceiq.cloudbreak.tag.request.CDPTagMergeRequest)1 Telemetry (com.sequenceiq.common.api.telemetry.model.Telemetry)1 EnvironmentNetworkResponse (com.sequenceiq.environment.api.v1.environment.model.response.EnvironmentNetworkResponse)1 BeforeEach (org.junit.jupiter.api.BeforeEach)1