aboutsummaryrefslogtreecommitdiffstats
path: root/plans/so/integration-etsi-testing/so-simulators/sdc-simulator
diff options
context:
space:
mode:
authorFu Jinhua <fu.jinhua@zte.com.cn>2019-08-02 00:16:21 +0000
committerGerrit Code Review <gerrit@onap.org>2019-08-02 00:16:21 +0000
commit137509e293ae559e3b5fc0d5454421003e3604b2 (patch)
treebfd5a7a819f6627b4dc178c2ba76d2b3674f7d1c /plans/so/integration-etsi-testing/so-simulators/sdc-simulator
parent6527be9fc2ac737cab4b60016ba04a3971a641d5 (diff)
parent24805416f0502a1e06bf57fd15c27d56150f3b30 (diff)
Merge "Adding infrastructure for sdnc simulator"
Diffstat (limited to 'plans/so/integration-etsi-testing/so-simulators/sdc-simulator')
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/pom.xml2
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/utils/Constants.java41
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/SdcSimulatorApplication.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/SdcSimulatorApplication.java)2
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/configration/WebSecurityConfigImpl.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/configration/WebSecurityConfigImpl.java)4
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/CatalogController.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/CatalogController.java)6
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/SdcSimulatorController.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/SdcSimulatorController.java)4
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProvider.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProvider.java)2
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProviderImpl.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProviderImpl.java)4
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/utils/Constants.java45
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/CatalogControllerTest.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/CatalogControllerTest.java)7
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/SdcSimulatorControllerTest.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/SdcSimulatorControllerTest.java)4
-rw-r--r--plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/providers/ResourceProviderImplTest.java (renamed from plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/providers/ResourceProviderImplTest.java)5
12 files changed, 66 insertions, 60 deletions
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/pom.xml b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/pom.xml
index e5cc3d32..27e7c3ea 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/pom.xml
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/pom.xml
@@ -26,7 +26,7 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
- <mainClass>org.onap.so.sdc.simulator.SdcSimulatorApplication</mainClass>
+ <mainClass>org.onap.so.sdcsimulator.SdcSimulatorApplication</mainClass>
</configuration>
<executions>
<execution>
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/utils/Constants.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/utils/Constants.java
deleted file mode 100644
index 4fa06881..00000000
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/utils/Constants.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * ============LICENSE_START======================================================= Copyright (C) 2019 Nordix
- * Foundation. ================================================================================ Licensed under the
- * Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may
- * obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
- * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations under the License.
- *
- * SPDX-License-Identifier: Apache-2.0 ============LICENSE_END=========================================================
- */
-
-package org.onap.so.sdc.simulator.utils;
-
-/**
- * @author Waqas Ikram (waqas.ikram@est.tech)
- */
-public class Constants {
-
- public static final String BASE_URL = "/sdc/v1";
-
- public static final String CATALOG_URL = BASE_URL + "/catalog";
-
- public static final String HEALTHY = "healthy";
-
- public static final String DEFAULT_CSAR_NAME = "default_csar_file";
-
- public static final String DOT = ".";
-
- public static final String DOT_CSAR = DOT + "csar";
-
- public static final String DEFAULT_CSAR_NAME_WITH_EXT = DEFAULT_CSAR_NAME + DOT_CSAR;
-
- public static final String DEFAULT_CSAR_PATH = "/csar/" + DEFAULT_CSAR_NAME_WITH_EXT;
-
-
- private Constants() {}
-}
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/SdcSimulatorApplication.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/SdcSimulatorApplication.java
index abb183b1..25d21e53 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/SdcSimulatorApplication.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/SdcSimulatorApplication.java
@@ -18,7 +18,7 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator;
+package org.onap.so.sdcsimulator;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/configration/WebSecurityConfigImpl.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/configration/WebSecurityConfigImpl.java
index bf971785..b2c51369 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/configration/WebSecurityConfigImpl.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/configration/WebSecurityConfigImpl.java
@@ -17,9 +17,9 @@
* SPDX-License-Identifier: Apache-2.0
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.configration;
+package org.onap.so.sdcsimulator.configration;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/CatalogController.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/CatalogController.java
index 01c0b39f..e9f17762 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/CatalogController.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/CatalogController.java
@@ -17,12 +17,12 @@
* SPDX-License-Identifier: Apache-2.0
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.controller;
+package org.onap.so.sdcsimulator.controller;
-import static org.onap.so.sdc.simulator.utils.Constants.CATALOG_URL;
+import static org.onap.so.sdcsimulator.utils.Constants.CATALOG_URL;
import java.util.Optional;
import javax.ws.rs.core.MediaType;
-import org.onap.so.sdc.simulator.providers.ResourceProvider;
+import org.onap.so.sdcsimulator.providers.ResourceProvider;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/SdcSimulatorController.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/SdcSimulatorController.java
index 2baf2038..4cd564d4 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/controller/SdcSimulatorController.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/controller/SdcSimulatorController.java
@@ -18,10 +18,10 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.controller;
+package org.onap.so.sdcsimulator.controller;
import javax.ws.rs.core.MediaType;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.HttpStatus;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProvider.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProvider.java
index 83994b4b..4d5dcdd0 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProvider.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProvider.java
@@ -18,7 +18,7 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.providers;
+package org.onap.so.sdcsimulator.providers;
import java.io.IOException;
import java.io.InputStream;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProviderImpl.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProviderImpl.java
index efc98de7..192ac896 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdc/simulator/providers/ResourceProviderImpl.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/providers/ResourceProviderImpl.java
@@ -18,7 +18,7 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.providers;
+package org.onap.so.sdcsimulator.providers;
import java.io.IOException;
import java.io.InputStream;
@@ -26,7 +26,7 @@ import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.Optional;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/utils/Constants.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/utils/Constants.java
new file mode 100644
index 00000000..e8412574
--- /dev/null
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/main/java/org/onap/so/sdcsimulator/utils/Constants.java
@@ -0,0 +1,45 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * Copyright (C) 2019 Nordix Foundation.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * SPDX-License-Identifier: Apache-2.0
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.sdcsimulator.utils;
+
+/**
+ * @author Waqas Ikram (waqas.ikram@est.tech)
+ */
+public class Constants {
+
+ public static final String BASE_URL = "/sdc/v1";
+
+ public static final String CATALOG_URL = BASE_URL + "/catalog";
+
+ public static final String HEALTHY = "healthy";
+
+ public static final String DEFAULT_CSAR_NAME = "default_csar_file";
+
+ public static final String DOT = ".";
+
+ public static final String DOT_CSAR = DOT + "csar";
+
+ public static final String DEFAULT_CSAR_NAME_WITH_EXT = DEFAULT_CSAR_NAME + DOT_CSAR;
+
+ public static final String DEFAULT_CSAR_PATH = "/csar/" + DEFAULT_CSAR_NAME_WITH_EXT;
+
+ private Constants() {}
+}
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/CatalogControllerTest.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/CatalogControllerTest.java
index 98ec448e..ca55f495 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/CatalogControllerTest.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/CatalogControllerTest.java
@@ -17,7 +17,7 @@
* SPDX-License-Identifier: Apache-2.0
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.controller;
+package org.onap.so.sdcsimulator.controller;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
@@ -27,8 +27,9 @@ import java.util.Optional;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mockito;
-import org.onap.so.sdc.simulator.providers.ResourceProvider;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.controller.CatalogController;
+import org.onap.so.sdcsimulator.providers.ResourceProvider;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.test.context.SpringBootTest;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/SdcSimulatorControllerTest.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/SdcSimulatorControllerTest.java
index 300b62a8..9789f812 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/controller/SdcSimulatorControllerTest.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/controller/SdcSimulatorControllerTest.java
@@ -18,12 +18,12 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.controller;
+package org.onap.so.sdcsimulator.controller;
import static org.junit.Assert.assertEquals;
import org.junit.Test;
import org.junit.runner.RunWith;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
diff --git a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/providers/ResourceProviderImplTest.java b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/providers/ResourceProviderImplTest.java
index b112c403..e575f2a5 100644
--- a/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdc/simulator/providers/ResourceProviderImplTest.java
+++ b/plans/so/integration-etsi-testing/so-simulators/sdc-simulator/src/test/java/org/onap/so/sdcsimulator/providers/ResourceProviderImplTest.java
@@ -18,7 +18,7 @@
* ============LICENSE_END=========================================================
*/
-package org.onap.so.sdc.simulator.providers;
+package org.onap.so.sdcsimulator.providers;
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertFalse;
@@ -30,7 +30,8 @@ import java.nio.file.Path;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.TemporaryFolder;
-import org.onap.so.sdc.simulator.utils.Constants;
+import org.onap.so.sdcsimulator.providers.ResourceProviderImpl;
+import org.onap.so.sdcsimulator.utils.Constants;
import org.springframework.core.io.ClassPathResource;
import org.springframework.util.StreamUtils;