summaryrefslogtreecommitdiffstats
path: root/vid-automation/src/main/java/org/opencomp
diff options
context:
space:
mode:
authorkurczews <krzysztof.kurczewski@nokia.com>2018-08-13 12:42:35 +0200
committerkurczews <krzysztof.kurczewski@nokia.com>2018-08-13 12:46:44 +0200
commit5015d4aa2a7ba17d5e7024bf9ef344e7b320b9ab (patch)
tree785a347ef14348ee75746dc8e465b629819719dd /vid-automation/src/main/java/org/opencomp
parent5ac1100c02912f7a45d2949d94cd33d054283139 (diff)
Renaming vid-automation #2
Change-Id: Ide2d71658369e0f0d953e1aa1752f48e9a4bbe96 Issue-ID: VID-205 Signed-off-by: kurczews <krzysztof.kurczewski@nokia.com>
Diffstat (limited to 'vid-automation/src/main/java/org/opencomp')
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseAAIPreset.java12
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseEcompPortalPreset.java12
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPreset.java30
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPresetServiceInstanceOperationsPost.java33
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BasePreset.java47
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseSDCPreset.java12
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/EcompPortalPresetsUtils.java18
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetExtendSessionTimeOutsPost.java18
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetSessionSlotCheckIntervalGet.java18
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetUserGet.java20
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/RegistrationRequest.java54
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/Subscriber.java19
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceMetadataGet.java50
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceToscaModelGet.java30
-rw-r--r--vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/SdcPresetWithModelVersionId.java22
15 files changed, 0 insertions, 395 deletions
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseAAIPreset.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseAAIPreset.java
deleted file mode 100644
index d75b41ee8..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseAAIPreset.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-/**
- * Created by itzikliderman on 27/12/2017.
- */
-public abstract class BaseAAIPreset extends BasePreset {
-
- @Override
- protected String getRootPath() {
- return "/aai/v..";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseEcompPortalPreset.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseEcompPortalPreset.java
deleted file mode 100644
index d073a7164..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseEcompPortalPreset.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-/**
- * Created by itzikliderman on 27/12/2017.
- */
-public abstract class BaseEcompPortalPreset extends BasePreset {
-
- @Override
- protected String getRootPath() {
- return "/ecompportal_att/auxapi";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPreset.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPreset.java
deleted file mode 100644
index e30bdefeb..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPreset.java
+++ /dev/null
@@ -1,30 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-import vid.automation.test.infra.Features;
-
-/**
- * Created by itzikliderman on 27/12/2017.
- */
-public abstract class BaseMSOPreset extends BasePreset {
-
- public static String getRequestBodyWithTestApiOnly() {
- if (Features.FLAG_ADD_MSO_TESTAPI_FIELD.isActive()) {
- return "" +
- "{" +
- " \"requestDetails\": { " +
- " \"requestParameters\": { " +
- " \"testApi\": \"GR_API\" " +
- " } " +
- " } " +
- "} " +
- "";
- } else {
- return null;
- }
- }
-
- @Override
- protected String getRootPath() {
- return "/mso";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPresetServiceInstanceOperationsPost.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPresetServiceInstanceOperationsPost.java
deleted file mode 100644
index 8f298c45a..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseMSOPresetServiceInstanceOperationsPost.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-import org.springframework.http.HttpMethod;
-
-/**
- * Created by itzikliderman on 21/12/2017.
- */
-public abstract class BaseMSOPresetServiceInstanceOperationsPost extends BaseMSOPreset {
- @Override
- protected String getRootPath() {
- return super.getRootPath() + "/cloudResources/v1/operationalEnvironments/ENV-UUID";
- }
-
- @Override
- public Object getResponseBody() {
- return "{"+
- " \"requestReferences\": {"+
- " \"instanceId\": \"dbe54591-c8ed-46d3-abc7-d3a24873dfbd\","+
- " \"requestId\": \"dbe54591-c8ed-46d3-abc7-d3a24873sssa\""+
- " }"+
- " }";
- }
-
- @Override
- public HttpMethod getReqMethod() {
- return HttpMethod.POST;
- }
-
- @Override
- public int getResponseCode() {
- return 202;
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BasePreset.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BasePreset.java
deleted file mode 100644
index 51ba8590c..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BasePreset.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-import org.opencomp.simulator.presetGenerator.presets.model.RegistrationRequest;
-import org.springframework.http.HttpMethod;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Created by itzikliderman on 13/12/2017.
- */
-public abstract class BasePreset {
-
- public RegistrationRequest generateScenario() {
- Map<String, String> headers = new HashMap<>();
- headers.put("Content-Type", getContentType());
-
- return new RegistrationRequest(
- new RegistrationRequest.SimulatorRequest(getReqMethod(), getReqPath(), getQueryParams(), getRequestBody()),
- new RegistrationRequest.SimulatorResponse(getResponseCode(), headers, getResponseBody(), getFile()));
- }
-
- public Object getResponseBody() { return null; };
-
- public String getContentType() {
- return "application/json";
- }
-
- public String getFile() {
- return null;
- }
-
- public int getResponseCode() { return 200; }
-
- public abstract HttpMethod getReqMethod();
-
- public abstract String getReqPath();
-
- public Object getRequestBody() {
- return null;
- }
-
- public Map<String, List> getQueryParams() { return null; }
-
- protected abstract String getRootPath();
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseSDCPreset.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseSDCPreset.java
deleted file mode 100644
index ef64450b1..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/BasePresets/BaseSDCPreset.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.BasePresets;
-
-/**
- * Created by itzikliderman on 27/12/2017.
- */
-public abstract class BaseSDCPreset extends BasePreset {
-
- @Override
- protected String getRootPath() {
- return "/sdc/v1/catalog/services";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/EcompPortalPresetsUtils.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/EcompPortalPresetsUtils.java
deleted file mode 100644
index 5363eac4a..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/EcompPortalPresetsUtils.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.ecompportal_att;
-
-import org.opencomp.simulator.presetGenerator.presets.BasePresets.BasePreset;
-
-import java.util.Arrays;
-import java.util.List;
-
-public class EcompPortalPresetsUtils {
-
- private final static List<BasePreset> ecompPortalPresets = Arrays.asList(
- new PresetGetUserGet(),
- new PresetGetSessionSlotCheckIntervalGet(),
- new PresetExtendSessionTimeOutsPost());
-
- public static List<BasePreset> getEcompPortalPresets() {
- return ecompPortalPresets;
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetExtendSessionTimeOutsPost.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetExtendSessionTimeOutsPost.java
deleted file mode 100644
index c8d61df25..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetExtendSessionTimeOutsPost.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.ecompportal_att;
-
-import org.opencomp.simulator.presetGenerator.presets.BasePresets.BaseEcompPortalPreset;
-import org.springframework.http.HttpMethod;
-
-public class PresetExtendSessionTimeOutsPost extends BaseEcompPortalPreset {
- public Object getResponseBody() {
- return "300000";
- }
-
- public HttpMethod getReqMethod() {
- return HttpMethod.POST;
- }
-
- public String getReqPath() {
- return getRootPath() + "//extendSessionTimeOuts";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetSessionSlotCheckIntervalGet.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetSessionSlotCheckIntervalGet.java
deleted file mode 100644
index c35dfcda5..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetSessionSlotCheckIntervalGet.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.ecompportal_att;
-
-import org.opencomp.simulator.presetGenerator.presets.BasePresets.BaseEcompPortalPreset;
-import org.springframework.http.HttpMethod;
-
-public class PresetGetSessionSlotCheckIntervalGet extends BaseEcompPortalPreset {
- public Object getResponseBody() {
- return "300000";
- }
-
- public HttpMethod getReqMethod() {
- return HttpMethod.GET;
- }
-
- public String getReqPath() {
- return getRootPath() + "//getSessionSlotCheckInterval";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetUserGet.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetUserGet.java
deleted file mode 100644
index b046b77c8..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/ecompportal_att/PresetGetUserGet.java
+++ /dev/null
@@ -1,20 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.ecompportal_att;
-
-import org.opencomp.simulator.presetGenerator.presets.BasePresets.BaseEcompPortalPreset;
-import org.springframework.http.HttpMethod;
-
-import java.util.Collections;
-
-public class PresetGetUserGet extends BaseEcompPortalPreset {
- public Object getResponseBody() {
- return Collections.EMPTY_LIST;
- }
-
- public HttpMethod getReqMethod() {
- return HttpMethod.GET;
- }
-
- public String getReqPath() {
- return getRootPath() + "/context/get_user";
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/RegistrationRequest.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/RegistrationRequest.java
deleted file mode 100644
index 2b1cdeb5c..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/RegistrationRequest.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.model;
-
-import com.fasterxml.jackson.annotation.JsonInclude;
-import org.springframework.http.HttpMethod;
-
-import java.util.List;
-import java.util.Map;
-
-public class RegistrationRequest {
-
- public static class SimulatorRequest {
- public final HttpMethod method;
- public final String path;
-
- @JsonInclude(JsonInclude.Include.NON_NULL)
- public final Map<String,List> queryParams;
-
- @JsonInclude(JsonInclude.Include.NON_NULL)
- public final Object body;
-
- public SimulatorRequest(HttpMethod method, String path, Map<String, List> queryParams, Object body) {
- this.method = method;
- this.path = path;
- this.queryParams = queryParams;
- this.body = body;
- }
- }
-
- public static class SimulatorResponse {
- public final int responseCode;
- public final Map<String,String> responseHeaders;
-
- @JsonInclude(JsonInclude.Include.NON_NULL)
- public final Object body;
-
- @JsonInclude(JsonInclude.Include.NON_NULL)
- public final String file;
-
- public SimulatorResponse(int responseCode, Map<String, String> responseHeaders, Object body, String file) {
- this.responseCode = responseCode;
- this.responseHeaders = responseHeaders;
- this.body = body;
- this.file = file;
- }
- }
-
- public SimulatorRequest simulatorRequest;
- public SimulatorResponse simulatorResponse;
-
- public RegistrationRequest(SimulatorRequest simulatorRequest, SimulatorResponse simulatorResponse) {
- this.simulatorRequest = simulatorRequest;
- this.simulatorResponse = simulatorResponse;
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/Subscriber.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/Subscriber.java
deleted file mode 100644
index 0ec3b18c5..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/model/Subscriber.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.model;
-
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-public class Subscriber {
-
- @JsonProperty("global-customer-id")
- public String globalCustomerId;
-
- @JsonProperty("subscriber-name")
- public String subscriberName;
-
- @JsonProperty("subscriber-type")
- public String subscriberType;
-
- @JsonProperty("resource-version")
- public String resourceVersion;
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceMetadataGet.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceMetadataGet.java
deleted file mode 100644
index 7ec6e0e2b..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceMetadataGet.java
+++ /dev/null
@@ -1,50 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.sdc;
-
-import org.springframework.http.HttpMethod;
-
-/**
- * Created by itzikliderman on 21/12/2017.
- */
-public class PresetSDCGetServiceMetadataGet extends SdcPresetWithModelVersionId {
-
- public PresetSDCGetServiceMetadataGet(String modelVersionId, String modelInvariantId, String zipFileName) {
- super(modelVersionId);
- this.modelInvariantId = modelInvariantId;
- this.zipFileName = zipFileName;
- }
-
- private final String zipFileName;
- private final String modelInvariantId;
-
-
- @Override
- public Object getResponseBody() {
- return "{" +
- " \"uuid\": \""+getModelVersionId()+"\"," +
- " \"invariantUUID\": \""+getModelInvariantId()+"\"," +
- " \"name\": \"action-data\"," +
- " \"version\": \"1.0\"," +
- " \"toscaModelURL\": \"./"+zipFileName+"\"," +
- " \"category\": \"Mobility\"," +
- " \"lifecycleState\": \"CERTIFIED\"," +
- " \"lastUpdaterUserId\": \"rg276b\"," +
- " \"lastUpdaterFullName\": null," +
- " \"distributionStatus\": \"DISTRIBUTED\"," +
- " \"artifacts\": null," +
- " \"resources\": null" +
- " }";
- }
-
- public HttpMethod getReqMethod() {
- return HttpMethod.GET;
- }
-
- @Override
- public String getReqPath() {
- return super.getReqPath()+"/metadata";
- }
-
- public String getModelInvariantId() {
- return modelInvariantId;
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceToscaModelGet.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceToscaModelGet.java
deleted file mode 100644
index cb2276829..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/PresetSDCGetServiceToscaModelGet.java
+++ /dev/null
@@ -1,30 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.sdc;
-
-import org.springframework.http.HttpMethod;
-
-/**
- * Created by itzikliderman on 21/12/2017.
- */
-public class PresetSDCGetServiceToscaModelGet extends SdcPresetWithModelVersionId {
-
- private String file;
-
- public PresetSDCGetServiceToscaModelGet(String modelVersionId, String file) {
- super(modelVersionId);
- this.file = file;
- }
-
- public HttpMethod getReqMethod() {
- return HttpMethod.GET;
- }
-
- @Override
- public String getReqPath() {
- return super.getReqPath()+"/toscaModel";
- }
-
- @Override
- public String getFile() {
- return file;
- }
-}
diff --git a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/SdcPresetWithModelVersionId.java b/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/SdcPresetWithModelVersionId.java
deleted file mode 100644
index e8fdfa2b9..000000000
--- a/vid-automation/src/main/java/org/opencomp/simulator/presetGenerator/presets/sdc/SdcPresetWithModelVersionId.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package org.opencomp.simulator.presetGenerator.presets.sdc;
-
-import org.opencomp.simulator.presetGenerator.presets.BasePresets.BaseSDCPreset;
-
-public abstract class SdcPresetWithModelVersionId extends BaseSDCPreset {
-
- public SdcPresetWithModelVersionId(String modelVersionId) {
- this.modelVersionId = modelVersionId;
- }
-
- protected String modelVersionId;
-
- public String getModelVersionId() {
- return modelVersionId;
- }
-
- public String getReqPath() {
- return getRootPath() + "/"+getModelVersionId();
- }
-
-
-}