diff options
Diffstat (limited to 'prh-dmaap-client')
-rw-r--r-- | prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClient.java (renamed from prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClient.java) | 8 | ||||
-rw-r--r-- | prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClientTest.java (renamed from prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClientTest.java) | 12 |
2 files changed, 10 insertions, 10 deletions
diff --git a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClient.java b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClient.java index 6cd54846..6919487a 100644 --- a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClient.java +++ b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClient.java @@ -43,7 +43,7 @@ import reactor.core.publisher.Mono; /** * @author <a href="mailto:przemyslaw.wasala@nokia.com">Przemysław Wąsala</a> on 7/4/18 */ -public class DMaaPProducerReactiveHttpClient { +public class DMaaPPublisherReactiveHttpClient { private final String dmaapHostName; private final Integer dmaapPortNumber; @@ -54,11 +54,11 @@ public class DMaaPProducerReactiveHttpClient { private RestTemplate restTemplate; /** - * Constructor DMaaPProducerReactiveHttpClient. + * Constructor DMaaPPublisherReactiveHttpClient. * * @param dmaapPublisherConfiguration - DMaaP producer configuration object */ - public DMaaPProducerReactiveHttpClient(DmaapPublisherConfiguration dmaapPublisherConfiguration) { + public DMaaPPublisherReactiveHttpClient(DmaapPublisherConfiguration dmaapPublisherConfiguration) { this.dmaapHostName = dmaapPublisherConfiguration.dmaapHostName(); this.dmaapProtocol = dmaapPublisherConfiguration.dmaapProtocol(); this.dmaapPortNumber = dmaapPublisherConfiguration.dmaapPortNumber(); @@ -90,7 +90,7 @@ public class DMaaPProducerReactiveHttpClient { } - public DMaaPProducerReactiveHttpClient createDMaaPWebClient(RestTemplate restTemplate) { + public DMaaPPublisherReactiveHttpClient createDMaaPWebClient(RestTemplate restTemplate) { this.restTemplate = restTemplate; return this; } diff --git a/prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClientTest.java b/prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClientTest.java index 29d1039f..db3d515c 100644 --- a/prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPProducerReactiveHttpClientTest.java +++ b/prh-dmaap-client/src/test/java/org/onap/dcaegen2/services/prh/service/producer/DMaaPPublisherReactiveHttpClientTest.java @@ -45,9 +45,9 @@ import reactor.test.StepVerifier; * @author <a href="mailto:przemyslaw.wasala@nokia.com">Przemysław Wąsala</a> on 7/4/18 */ -class DMaaPProducerReactiveHttpClientTest { +class DMaaPPublisherReactiveHttpClientTest { - private DMaaPProducerReactiveHttpClient dmaapProducerReactiveHttpClient; + private DMaaPPublisherReactiveHttpClient dmaapPublisherReactiveHttpClient; private DmaapPublisherConfiguration dmaapPublisherConfigurationMock = mock( DmaapPublisherConfiguration.class); @@ -63,7 +63,7 @@ class DMaaPProducerReactiveHttpClientTest { when(dmaapPublisherConfigurationMock.dmaapUserPassword()).thenReturn("PRH"); when(dmaapPublisherConfigurationMock.dmaapContentType()).thenReturn("application/json"); when(dmaapPublisherConfigurationMock.dmaapTopicName()).thenReturn("unauthenticated.PNF_READY"); - dmaapProducerReactiveHttpClient = new DMaaPProducerReactiveHttpClient(dmaapPublisherConfigurationMock); + dmaapPublisherReactiveHttpClient = new DMaaPPublisherReactiveHttpClient(dmaapPublisherConfigurationMock); } @@ -77,16 +77,16 @@ class DMaaPProducerReactiveHttpClientTest { when(mockedResponseEntity.getStatusCode()).thenReturn(HttpStatus.valueOf(responseSuccess)); doReturn(mockedResponseEntity).when(restTemplate) .exchange(any(URI.class), any(HttpMethod.class), any(HttpEntity.class), (Class<Object>) any()); - dmaapProducerReactiveHttpClient.createDMaaPWebClient(restTemplate); + dmaapPublisherReactiveHttpClient.createDMaaPWebClient(restTemplate); //then - StepVerifier.create(dmaapProducerReactiveHttpClient.getDMaaPProducerResponse(consumerDmaapModel)) + StepVerifier.create(dmaapPublisherReactiveHttpClient.getDMaaPProducerResponse(consumerDmaapModel)) .expectSubscription().expectNext(mockedResponseEntity).verifyComplete(); } @Test void getAppropriateUri_whenPassingCorrectedPathForPnf() { - Assertions.assertEquals(dmaapProducerReactiveHttpClient.getUri(), + Assertions.assertEquals(dmaapPublisherReactiveHttpClient.getUri(), URI.create("https://54.45.33.2:1234/unauthenticated.PNF_READY")); } }
\ No newline at end of file |