From fca9385739569e4bcf27903ebde80e078b3530b9 Mon Sep 17 00:00:00 2001 From: Guangrong Fu Date: Wed, 24 Jan 2018 10:40:37 +0800 Subject: Add Unit Tests Change-Id: I972623ad6ab9b7ab06f4996614a37a51b4cedde5 Issue-ID: HOLMES-97 Signed-off-by: Guangrong Fu --- .../src/main/java/org/onap/holmes/common/dmaap/Publisher.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'holmes-actions/src/main/java/org') diff --git a/holmes-actions/src/main/java/org/onap/holmes/common/dmaap/Publisher.java b/holmes-actions/src/main/java/org/onap/holmes/common/dmaap/Publisher.java index 0f96181..91e9d42 100644 --- a/holmes-actions/src/main/java/org/onap/holmes/common/dmaap/Publisher.java +++ b/holmes-actions/src/main/java/org/onap/holmes/common/dmaap/Publisher.java @@ -57,12 +57,12 @@ public class Publisher { response = webTarget.request(MediaType.APPLICATION_JSON) .post(Entity.entity(content, MediaType.APPLICATION_JSON)); } catch (Exception e) { - throw new CorrelationException("Failed to connect dcae.", e); + throw new CorrelationException("Failed to connect to DCAE.", e); } return checkStatus(response); } private boolean checkStatus(Response response) { - return (response.getStatus() == HttpStatus.SC_OK) ? true : false; + return response.getStatus() == HttpStatus.SC_OK; } } -- cgit 1.2.3-korg