summaryrefslogtreecommitdiffstats
path: root/src/test
diff options
context:
space:
mode:
authorsunil unnava <su622b@att.com>2019-03-18 15:40:17 +0000
committerGerrit Code Review <gerrit@onap.org>2019-03-18 15:40:17 +0000
commite3da91b4013e3c4fea1d2a2c6f0e4a1677fb3ba4 (patch)
treed4645234f1bc489cedd1ab4a26f88de08c2445e7 /src/test
parent4a8983cbc2b63c24c082efd163a32aa98e2820d8 (diff)
parent2ce8d15a4d5c03bb4f2f676114c466b61c4a3188 (diff)
Merge "Sonar fix too many method param"
Diffstat (limited to 'src/test')
-rw-r--r--src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
index 6279d82..38c7f8a 100644
--- a/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
@@ -251,8 +251,14 @@ public class MRBaseClientTest {
"password", new String("{\"test\":\"test\"}").getBytes(), "application/json"))
.thenReturn(response);
- mrBaseClient.postAuth("/path", new String("{\"test\":\"test\"}").getBytes(), "application/json", "username",
- "password", "username", "password", "HTTPAUTH");
+ mrBaseClient.postAuth(new PostAuthDataObject().setPath("/path")
+ .setData( new String("{\"test\":\"test\"}").getBytes())
+ .setContentType("application/json")
+ .setAuthKey("username")
+ .setAuthDate("password")
+ .setUsername("username")
+ .setPassword("password")
+ .setProtocolFlag("HTTPAUTH"));
assertTrue(true);
}
@@ -266,9 +272,16 @@ public class MRBaseClientTest {
"password", new String("{\"test\":\"test\"}").getBytes(), "application/json"))
.thenReturn(
responseBuilder.header("transactionid", "transactionid").entity("{\"test\":\"test\"}").build());
-
- mrBaseClient.postAuth("/path", new String("{\"test\":\"test\"}").getBytes(), "application/json", null, null,
- null, null, "HTTPAUTH");
+
+ mrBaseClient.postAuth(new PostAuthDataObject().setPath("/path")
+ .setData( new String("{\"test\":\"test\"}").getBytes())
+ .setContentType("application/json")
+ .setAuthKey(null)
+ .setAuthDate(null)
+ .setUsername(null)
+ .setPassword(null)
+ .setProtocolFlag("HTTPAUTH"));
+
assertTrue(true);
}