summaryrefslogtreecommitdiffstats
path: root/vid-automation/src/test/java/org/onap
diff options
context:
space:
mode:
authorAlexey Sandler <alexey.sandler@intl.att.com>2020-03-16 21:47:40 +0200
committerAlexey Sandler <alexey.sandler@intl.att.com>2020-03-16 21:47:40 +0200
commit6b57c89aa2ceda72126576c8cdb58b75e83df6f1 (patch)
tree8424b3969939a943170753577add63c1ad352f7d /vid-automation/src/test/java/org/onap
parent212533a0274fd52384c02b929d435e4fb6aeed82 (diff)
API test to verify simpleNoTaskInfo format
Use new format when fetching Orchestration requests from MSO to the CM dashboard Issue-ID: VID-787 Signed-off-by: Alexey Sandler <alexey.sandler@intl.att.com> Change-Id: Id426ee13ce9dede540d7807cb836f1bb6db420c2
Diffstat (limited to 'vid-automation/src/test/java/org/onap')
-rw-r--r--vid-automation/src/test/java/org/onap/vid/api/ChangeManagementApiTest.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/vid-automation/src/test/java/org/onap/vid/api/ChangeManagementApiTest.java b/vid-automation/src/test/java/org/onap/vid/api/ChangeManagementApiTest.java
index 6416244aa..108506e6d 100644
--- a/vid-automation/src/test/java/org/onap/vid/api/ChangeManagementApiTest.java
+++ b/vid-automation/src/test/java/org/onap/vid/api/ChangeManagementApiTest.java
@@ -1,5 +1,6 @@
package org.onap.vid.api;
+import static net.javacrumbs.jsonunit.JsonMatchers.jsonEquals;
import static org.hamcrest.CoreMatchers.containsString;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.core.IsEqual.equalTo;
@@ -7,7 +8,6 @@ import static org.hamcrest.core.IsInstanceOf.instanceOf;
import static org.onap.vid.api.ChangeManagementUserApiLoggingTest.MSO_GET_CHANGE_MANAGEMENTS_SCALEOUT;
import static org.onap.vid.api.TestUtils.getNestedPropertyInMap;
import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertFalse;
import static vid.automation.test.services.SimulatorApi.RegistrationStrategy.APPEND;
import com.google.common.collect.ImmutableList;
@@ -302,12 +302,13 @@ public class ChangeManagementApiTest extends BaseApiTest {
@Test
@FeatureTogglingTest(Features.FLAG_EXP_USE_FORMAT_PARAMETER_FOR_CM_DASHBOARD)
- public void getOrchestrationForDashboardShouldResponseWithFullBody() {
+ public void getOrchestrationForDashboardShouldResponseWithNoTaskInfoBody() {
SimulatorApi.registerExpectation(MSO_GET_CHANGE_MANAGEMENTS_SCALEOUT, RegistrationStrategy.CLEAR_THEN_SET);
SimulatorApi.registerExpectationFromPreset(new PresetMSOOrchestrationRequestsGetNoTaskInfoBody(), APPEND);
ResponseEntity<String> responseEntity = restTemplate.getForEntity(buildUri(CHANGE_MANAGEMENT + MSO ), String.class);
- assertFalse(responseEntity.getBody().contains("requestProcessingData"));
+ String expected = getResourceAsString("changeManagement/responseNoTaskInfoBody.json");
+ assertThat(responseEntity.getBody(), jsonEquals(expected));
}