aboutsummaryrefslogtreecommitdiffstats
path: root/common/src/test/java/org/onap/so/client/HttpClientTest.java
diff options
context:
space:
mode:
authorBenjamin, Max (mb388a) <mb388a@us.att.com>2019-03-20 14:12:06 -0400
committerBenjamin, Max (mb388a) <mb388a@us.att.com>2019-04-01 09:45:03 -0400
commitaaa93d4351b712762d6951a8c82bbe84c2077795 (patch)
tree69dab8e5203fe3aa6afb0a26b4da101213a3bf9f /common/src/test/java/org/onap/so/client/HttpClientTest.java
parent24117e55159518d2e3599fd7cf6705d476cfda81 (diff)
replace all fixed wiremock ports
trying to get the tests that can be threaded to pass started to remove fixed port references Change-Id: I7bfe067a8f36c908039700646571681321e9a6f5 Issue-ID: SO-1676 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'common/src/test/java/org/onap/so/client/HttpClientTest.java')
-rw-r--r--common/src/test/java/org/onap/so/client/HttpClientTest.java11
1 files changed, 6 insertions, 5 deletions
diff --git a/common/src/test/java/org/onap/so/client/HttpClientTest.java b/common/src/test/java/org/onap/so/client/HttpClientTest.java
index 75ce5f322f..346bf1426d 100644
--- a/common/src/test/java/org/onap/so/client/HttpClientTest.java
+++ b/common/src/test/java/org/onap/so/client/HttpClientTest.java
@@ -25,18 +25,19 @@ import static com.github.tomakehurst.wiremock.client.WireMock.equalTo;
import static com.github.tomakehurst.wiremock.client.WireMock.exactly;
import static com.github.tomakehurst.wiremock.client.WireMock.post;
import static com.github.tomakehurst.wiremock.client.WireMock.postRequestedFor;
-import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
import static com.github.tomakehurst.wiremock.client.WireMock.verify;
import static com.github.tomakehurst.wiremock.core.WireMockConfiguration.wireMockConfig;
-import com.github.tomakehurst.wiremock.junit.WireMockRule;
import java.net.MalformedURLException;
import java.net.URL;
+
import org.junit.Rule;
import org.junit.Test;
import org.onap.so.utils.TargetEntity;
+import com.github.tomakehurst.wiremock.junit.WireMockRule;
+
public class HttpClientTest{
@@ -47,7 +48,7 @@ public class HttpClientTest{
@Test
public void testPost_success() throws MalformedURLException{
- stubFor(post(urlEqualTo("/services/sdnc/post"))
+ wireMockRule.stubFor(post(urlEqualTo("/services/sdnc/post"))
.willReturn(aResponse().withStatus(200)
.withHeader("Content-Type", "application/json")
.withBody("")));
@@ -66,7 +67,7 @@ public class HttpClientTest{
@Test
public void testPost_nullHeader() throws MalformedURLException{
- stubFor(post(urlEqualTo("/services/sdnc/post"))
+ wireMockRule.stubFor(post(urlEqualTo("/services/sdnc/post"))
.willReturn(aResponse().withStatus(200)
.withHeader("Content-Type", "application/json")
.withBody("")));
@@ -86,7 +87,7 @@ public class HttpClientTest{
@Test
public void testPost_nullBasicAuth() throws MalformedURLException{
- stubFor(post(urlEqualTo("/services/sdnc/post"))
+ wireMockRule.stubFor(post(urlEqualTo("/services/sdnc/post"))
.willReturn(aResponse().withStatus(200)
.withHeader("Content-Type", "application/json")
.withBody("")));