summaryrefslogtreecommitdiffstats
path: root/rulemgt/src/test/java/org
diff options
context:
space:
mode:
authortang peng <tang.peng5@zte.com.cn>2020-08-25 00:37:36 +0000
committerGerrit Code Review <gerrit@onap.org>2020-08-25 00:37:36 +0000
commitc0bc3d2de8e7694d272c1d53392feea73bec6c66 (patch)
tree4f57eed45628b3528d56b773aa0a524045d28c0e /rulemgt/src/test/java/org
parentc9741cd13332a64a2aec32b72bd81f90c456107d (diff)
parent95b4f4645fe544c8f11651d7aa78381b24fc3769 (diff)
Merge "Fixed Some Vulnerability Issues"
Diffstat (limited to 'rulemgt/src/test/java/org')
-rw-r--r--rulemgt/src/test/java/org/onap/holmes/rulemgt/dcae/DcaeConfigurationPollingTest.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/rulemgt/src/test/java/org/onap/holmes/rulemgt/dcae/DcaeConfigurationPollingTest.java b/rulemgt/src/test/java/org/onap/holmes/rulemgt/dcae/DcaeConfigurationPollingTest.java
index 53e60c8..6b640b2 100644
--- a/rulemgt/src/test/java/org/onap/holmes/rulemgt/dcae/DcaeConfigurationPollingTest.java
+++ b/rulemgt/src/test/java/org/onap/holmes/rulemgt/dcae/DcaeConfigurationPollingTest.java
@@ -1,5 +1,5 @@
/**
- * Copyright 2017 ZTE Corporation.
+ * Copyright 2017-2020 ZTE Corporation.
* <p>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -15,7 +15,6 @@
*/
package org.onap.holmes.rulemgt.dcae;
-import com.alibaba.fastjson.JSONObject;
import org.apache.http.HttpResponse;
import org.apache.http.StatusLine;
import org.apache.http.client.methods.HttpDelete;
@@ -31,6 +30,7 @@ import org.junit.runner.RunWith;
import org.onap.holmes.common.dcae.DcaeConfigurationQuery;
import org.onap.holmes.common.dcae.entity.DcaeConfigurations;
import org.onap.holmes.common.dcae.entity.Rule;
+import org.onap.holmes.common.utils.GsonUtil;
import org.onap.holmes.common.utils.HttpsUtils;
import org.onap.holmes.rulemgt.bean.response.RuleQueryListResponse;
import org.onap.holmes.rulemgt.bean.response.RuleResult4API;
@@ -82,7 +82,7 @@ public class DcaeConfigurationPollingTest {
expect(HttpsUtils.getConditionalHttpsClient(30000)).andReturn(clientMock);
expect(HttpsUtils.get(anyObject(HttpGet.class), anyObject(HashMap.class), anyObject(CloseableHttpClient.class)))
.andReturn(httpResponseMock);
- expect(HttpsUtils.extractResponseEntity(httpResponseMock)).andReturn(JSONObject.toJSONString(ruleQueryListResponse));
+ expect(HttpsUtils.extractResponseEntity(httpResponseMock)).andReturn(GsonUtil.beanToJson(ruleQueryListResponse));
clientMock.close();
expectLastCall();