X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=models-interactions%2Fmodel-simulators%2Fsrc%2Ftest%2Fjava%2Forg%2Fonap%2Fpolicy%2Fsimulators%2FVfcSimulatorTest.java;h=d68e9dc5d026c4d6c2367a34b8ffc5c53b704937;hb=f7da60fabf647665d61f142a0d6ba9a9fc940106;hp=379cfd7bcd25b39033890c68fcb98378fd729ac8;hpb=93e2ba2e1756596323774398673736946b220090;p=policy%2Fmodels.git diff --git a/models-interactions/model-simulators/src/test/java/org/onap/policy/simulators/VfcSimulatorTest.java b/models-interactions/model-simulators/src/test/java/org/onap/policy/simulators/VfcSimulatorTest.java index 379cfd7bc..d68e9dc5d 100644 --- a/models-interactions/model-simulators/src/test/java/org/onap/policy/simulators/VfcSimulatorTest.java +++ b/models-interactions/model-simulators/src/test/java/org/onap/policy/simulators/VfcSimulatorTest.java @@ -3,7 +3,7 @@ * simulators * ================================================================================ * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. - * Modifications Copyright (C) 2019 Nordix Foundation. + * Modifications Copyright (C) 2019-2020 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,12 +26,12 @@ import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; import java.util.HashMap; +import org.apache.commons.lang3.tuple.Pair; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; import org.onap.policy.common.endpoints.http.server.HttpServletServerFactoryInstance; import org.onap.policy.rest.RestManager; -import org.onap.policy.rest.RestManager.Pair; import org.onap.policy.vfc.VfcResponse; import org.onap.policy.vfc.util.Serialization; @@ -60,8 +60,8 @@ public class VfcSimulatorTest { new RestManager().post("http://localhost:6668/api/nslcm/v1/ns/1234567890/heal", "username", "password", new HashMap(), "application/json", "Some Request Here"); assertNotNull(httpDetails); - assertTrue(httpDetails.first == 202); - final VfcResponse response = Serialization.gsonPretty.fromJson(httpDetails.second, VfcResponse.class); + assertTrue(httpDetails.getLeft() == 202); + final VfcResponse response = Serialization.gsonPretty.fromJson(httpDetails.getRight(), VfcResponse.class); assertNotNull(response); } @@ -70,7 +70,7 @@ public class VfcSimulatorTest { final Pair httpDetails = new RestManager().get("http://localhost:6668/api/nslcm/v1/jobs/1234", "username", "password", new HashMap()); assertNotNull(httpDetails); - final VfcResponse response = Serialization.gsonPretty.fromJson(httpDetails.second, VfcResponse.class); + final VfcResponse response = Serialization.gsonPretty.fromJson(httpDetails.getRight(), VfcResponse.class); assertNotNull(response); } }