summaryrefslogtreecommitdiffstats
path: root/adapters/mso-adapter-utils/src/test/resources
diff options
context:
space:
mode:
authorBenjamin, Max (mb388a) <mb388a@us.att.com>2018-07-30 15:56:09 -0400
committerBenjamin, Max (mb388a) <mb388a@us.att.com>2018-07-31 11:09:25 -0400
commit5a6a6de6f1a26a1897e4917a0df613e25a24eb70 (patch)
tree59a968f27b4b603aacc9d5e7b51fb598aeec5321 /adapters/mso-adapter-utils/src/test/resources
parentb6dc38501f3b746426b42d9de4cc883d894149e8 (diff)
Containerization feature of SO
Change-Id: I95381232eeefcd247a66a5cec370a8ce1c288e18 Issue-ID: SO-670 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'adapters/mso-adapter-utils/src/test/resources')
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/CloudSite.json9
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/Error.json5
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/Explanation.json6
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/GetNeutronNetwork.json45
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/HeatEnvironmentParameter.json4
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/HeatStack.json11
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParam.json7
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParamExpected.json5
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/NeutronError.json5
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackCreateNeutronNetworkResponse.json11
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Access.json53
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Roles.json10
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_StackId.json14
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_Created.json17
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_DeleteComplete.json17
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Tenant.json8
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_User.json11
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/__files/UpdateStack.json11
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/application-test.yaml50
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/cloud_config.json87
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/cloud_config_bad.json31
-rw-r--r--adapters/mso-adapter-utils/src/test/resources/logback-test.xml6
22 files changed, 304 insertions, 119 deletions
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/CloudSite.json b/adapters/mso-adapter-utils/src/test/resources/__files/CloudSite.json
new file mode 100644
index 0000000000..c86c98726b
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/CloudSite.json
@@ -0,0 +1,9 @@
+{
+ "region_id" : "regionId",
+ "identity_service_id" : "identityServiceId",
+ "aic_version" : "aicVersion",
+ "clli" : "clli",
+ "cloudify_id" : "cloudifyId",
+ "platform" : "platform",
+ "orchestrator" : "orchestrator"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/Error.json b/adapters/mso-adapter-utils/src/test/resources/__files/Error.json
new file mode 100644
index 0000000000..2d8136887e
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/Error.json
@@ -0,0 +1,5 @@
+{
+ "code" : 1,
+ "title" : "title",
+ "message" : "message"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/Explanation.json b/adapters/mso-adapter-utils/src/test/resources/__files/Explanation.json
new file mode 100644
index 0000000000..0ca060c64e
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/Explanation.json
@@ -0,0 +1,6 @@
+{
+ "explanation" : "explanation",
+ "code" : 1,
+ "title" : "title",
+ "error" : {}
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/GetNeutronNetwork.json b/adapters/mso-adapter-utils/src/test/resources/__files/GetNeutronNetwork.json
new file mode 100644
index 0000000000..822f87f427
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/GetNeutronNetwork.json
@@ -0,0 +1,45 @@
+{
+ "network": {
+ "admin_state_up": true,
+ "availability_zone_hints": [],
+ "availability_zones": [
+ "nova"
+ ],
+ "created_at": "2016-03-08T20:19:41",
+ "dns_domain": "my-domain.org.",
+ "id": "43173f6a-d699-414b-888f-ab243dda6dfe",
+ "ipv4_address_scope": null,
+ "ipv6_address_scope": null,
+ "l2_adjacency": false,
+ "mtu": 1500,
+ "name": "net1",
+ "port_security_enabled": true,
+ "project_id": "9bacb3c5d39d41a79512987f338cf177",
+ "qos_policy_id": "6a8454ade84346f59e8d40665f878b2e",
+ "revision_number": 1,
+ "router:external": false,
+ "segments": [
+ {
+ "provider:network_type": "vlan",
+ "provider:physical_network": "public",
+ "provider:segmentation_id": 2
+ },
+ {
+ "provider:network_type": "flat",
+ "provider:physical_network": "default",
+ "provider:segmentation_id": 0
+ }
+ ],
+ "shared": false,
+ "status": "ACTIVE",
+ "subnets": [
+ "54d6f61d-db07-451c-9ab3-b9609b6b6f0b"
+ ],
+ "tags": ["tag1,tag2"],
+ "tenant_id": "4fd44f30292945e481c7b8a0c8908869",
+ "updated_at": "2016-03-08T20:19:41",
+ "vlan_transparent": false,
+ "description": "",
+ "is_default": false
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/HeatEnvironmentParameter.json b/adapters/mso-adapter-utils/src/test/resources/__files/HeatEnvironmentParameter.json
new file mode 100644
index 0000000000..fbff1b564d
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/HeatEnvironmentParameter.json
@@ -0,0 +1,4 @@
+{
+ "name": "keyTest",
+ "value": "{\"type\":\"paramType\"}"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/HeatStack.json b/adapters/mso-adapter-utils/src/test/resources/__files/HeatStack.json
new file mode 100644
index 0000000000..411a3e0bd7
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/HeatStack.json
@@ -0,0 +1,11 @@
+{
+ "description" : "description",
+ "links" : [],
+ "stackStatusReason" : "stackStatusReason",
+ "stackName" : "stackName",
+ "updatedTime" : null,
+ "creationTime" : null,
+ "stackStatus" : "stackStatus",
+ "id" : "id",
+ "files" : {}
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParam.json b/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParam.json
new file mode 100644
index 0000000000..2200e0c57f
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParam.json
@@ -0,0 +1,7 @@
+{
+ "heatTemplateArtifactUuid" : "heatTemplateArtifactUuid",
+ "paramName" : "keyTest",
+ "required" : true,
+ "paramType" : "paramType",
+ "paramAlias" : "paramAlias"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParamExpected.json b/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParamExpected.json
new file mode 100644
index 0000000000..581249f8e1
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/HeatTemplateParamExpected.json
@@ -0,0 +1,5 @@
+{
+ "paramName" : "keyTest",
+ "required" : true,
+ "paramType" : "paramType"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/NeutronError.json b/adapters/mso-adapter-utils/src/test/resources/__files/NeutronError.json
new file mode 100644
index 0000000000..853f89c685
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/NeutronError.json
@@ -0,0 +1,5 @@
+{
+ "type" : "type",
+ "message" : "message",
+ "detail" : "detail"
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackCreateNeutronNetworkResponse.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackCreateNeutronNetworkResponse.json
new file mode 100644
index 0000000000..d92f92a873
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackCreateNeutronNetworkResponse.json
@@ -0,0 +1,11 @@
+{
+ "network":
+ {
+ "status": "ACTIVE",
+ "subnets": [],
+ "name": "net-name",
+ "admin_state_up": true,
+ "tenant_id": "388a70781bae4ca895f17b7f6293eb70",
+ "shared": false, "id": "2a4017ef-31ff-496a-9294-e96ecc3bc9c9"
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Access.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Access.json
new file mode 100644
index 0000000000..7153f8b672
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Access.json
@@ -0,0 +1,53 @@
+{
+ "access": {
+ "token": {
+ "id": "tokenId1234",
+ "issued_at": null,
+ "expires": "1517418429142",
+ "tenant": null
+ },
+ "serviceCatalog": [
+ {
+ "type": "orchestration",
+ "name": null,
+ "endpoints": [
+ {
+ "region": "regionOne",
+ "publicURL": "port",
+ "internalURL": null,
+ "adminURL": null
+ }
+ ],
+ "endpointsLinks": null
+ },
+ {
+ "type": "network",
+ "name": null,
+ "endpoints": [
+ {
+ "region": "regionOne",
+ "publicURL": "port",
+ "internalURL": null,
+ "adminURL": null
+ }
+ ],
+ "endpointsLinks": null
+ },
+ {
+ "type": "identity",
+ "name": null,
+ "endpoints": [
+ {
+ "region": "regionOne",
+ "publicURL": "port",
+ "internalURL": null,
+ "adminURL": null
+ }
+ ],
+ "endpointsLinks": null
+ }
+ ],
+ "user": null,
+ "metadata": null
+ }
+}
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Roles.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Roles.json
new file mode 100644
index 0000000000..47ae4488cd
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Roles.json
@@ -0,0 +1,10 @@
+{
+ "roles": [
+ {
+ "id": "admin",
+ "name": "admin",
+ "description": null,
+ "enabled": null
+ }
+ ]
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_StackId.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_StackId.json
new file mode 100644
index 0000000000..96e6e0fe8a
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_StackId.json
@@ -0,0 +1,14 @@
+{
+ "stack": {
+ "id": "da886914-efb2-4917-b335-c8381528d90b",
+ "links" : [
+ {
+ "href" : "port",
+ "rel" : "self"
+ }
+ ],
+ "stack_name": "name",
+ "stack_status": "CREATE_COMPLETE"
+
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_Created.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_Created.json
new file mode 100644
index 0000000000..477acadf81
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_Created.json
@@ -0,0 +1,17 @@
+{
+ "stack": {
+ "description": null,
+ "links": null,
+ "stack_status_reason": null,
+ "stack_name": "stackname",
+ "updated_time": null,
+ "creation_time": null,
+ "stack_status": "CREATE_COMPLETE",
+ "id": "stackId",
+ "files": null,
+ "outputs": null,
+ "parameters": {
+
+ }
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_DeleteComplete.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_DeleteComplete.json
new file mode 100644
index 0000000000..8612258eee
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Stack_DeleteComplete.json
@@ -0,0 +1,17 @@
+{
+ "stack": {
+ "description": null,
+ "links": null,
+ "stackStatusReason": null,
+ "stackName": null,
+ "updatedTime": null,
+ "creationTime": null,
+ "stack_status": "DELETE_COMPLETE",
+ "id": "stackId",
+ "files": null,
+ "outputs": null,
+ "parameters": {
+
+ }
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Tenant.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Tenant.json
new file mode 100644
index 0000000000..e8eebbbf7c
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_Tenant.json
@@ -0,0 +1,8 @@
+{
+ "tenant": {
+ "id": "tenantId",
+ "name": "testingTenantName",
+ "description": null,
+ "enabled": null
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_User.json b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_User.json
new file mode 100644
index 0000000000..d2f3ea2b0e
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/OpenstackResponse_User.json
@@ -0,0 +1,11 @@
+{
+ "user": {
+ "id": "msoId",
+ "username": "admin",
+ "password": null,
+ "tenantId": "tenantId",
+ "name": "testingTenantName",
+ "email": null,
+ "enabled": null
+ }
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/__files/UpdateStack.json b/adapters/mso-adapter-utils/src/test/resources/__files/UpdateStack.json
new file mode 100644
index 0000000000..0a09d599ba
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/__files/UpdateStack.json
@@ -0,0 +1,11 @@
+{
+ "description" : "description",
+ "links" : [],
+ "stackStatusReason" : "stackStatusReason",
+ "stackName" : "stackName",
+ "updatedTime" : null,
+ "creationTime" : null,
+ "stackStatus" : "UPDATE_COMPLETE",
+ "id" : "id",
+ "files" : {}
+} \ No newline at end of file
diff --git a/adapters/mso-adapter-utils/src/test/resources/application-test.yaml b/adapters/mso-adapter-utils/src/test/resources/application-test.yaml
new file mode 100644
index 0000000000..b584088587
--- /dev/null
+++ b/adapters/mso-adapter-utils/src/test/resources/application-test.yaml
@@ -0,0 +1,50 @@
+# will be used as entry in DB to say SITE OFF/ON for healthcheck
+# MSO Properties go here
+mso:
+ catalog:
+ db:
+ spring:
+ endpoint: "http://localhost:"
+ db:
+ auth: Basic YnBlbDptc28tZGItMTUwNyE=
+cloud_config:
+ identity_services:
+ MT_KEYSTONE:
+ identity_url: "http://localhost:${wiremock.server.port}/v2.0"
+ mso_id: "john"
+ mso_pass: "313DECE408AF7759D442D7B06DD9A6AA"
+ admin_tenant: "admin"
+ member_role: "_member_"
+ tenant_metadata: false
+ identity_server_type: "KEYSTONE"
+ identity_authentication_type: "USERNAME_PASSWORD"
+ cloud_sites:
+ regionOne:
+ region_id: "regionOne"
+ clli: "MT2"
+ aic_version: "2.5"
+ identity_service_id: "MT_KEYSTONE"
+ DEFAULT:
+ region_id: ""
+ clli: "MTN6"
+ aic_version: "3.0"
+ identity_service_id: "ORDM3"
+adapters:
+ po:
+ retryCodes: "504"
+ retryDelay: "5"
+ retryCount: "3"
+ tenant:
+ tenant_description: "ECOMP Tenant"
+ region_type: "single"
+ user_role: "admin"
+ success_status_string: "Success"
+ no_regions_status_string: "no regions"
+ orm_request_path: "/v1/orm/customers/"
+ x_aic_orm_client_string: "ECOMP-MSO"
+ keystone_url_version: "/v2.0"
+ keystone_reg_ex: "/[vV][0-9]"
+ orm_url_replace_this: "8080"
+ orm_url_replace_with_this: "7080"
+ quota_value: "10"
+ set_default_quota: "false"
diff --git a/adapters/mso-adapter-utils/src/test/resources/cloud_config.json b/adapters/mso-adapter-utils/src/test/resources/cloud_config.json
deleted file mode 100644
index ee3532fe15..0000000000
--- a/adapters/mso-adapter-utils/src/test/resources/cloud_config.json
+++ /dev/null
@@ -1,87 +0,0 @@
-{ "cloud_config": {
- "identity_services":
- {
- "MT_KEYSTONE":
- {
- "identity_url": "http://localhost:5000/v2.0",
- "mso_id": "john",
- "mso_pass": "FD205490A48D48475607C36B9AD902BF",
- "admin_tenant": "admin",
- "member_role": "_member_",
- "tenant_metadata": false,
- "identity_server_type": "KEYSTONE",
- "identity_authentication_type": "RACKSPACE_APIKEY"
- },
- "DAN_KEYSTONE":
- {
- "identity_url": "http://localhost:5000/v2.0",
- "mso_id": "mockId",
- "mso_pass": "BC59F80E38208A42ABB81ECCDD4FB3E4",
- "admin_tenant": "service",
- "member_role": "_member_",
- "tenant_metadata": false,
- "identity_server_type": "KEYSTONE",
- "identity_authentication_type": "USERNAME_PASSWORD"
- },
- "MTINJVCC101_DCP":
- {
- "identity_url": "http://localhost:5000/v2.0",
- "mso_id": "mockIdToo",
- "mso_pass": "95604B9EAAC4D77D74786FAE54177206",
- "admin_tenant": "service",
- "member_role": "admin",
- "tenant_metadata": true,
- "identity_server_type": "KEYSTONE",
- "identity_authentication_type": "USERNAME_PASSWORD"
- },
- "MTSNJA3DCP1":
- {
- "identity_url": "https://localhost:5000/v2.0",
- "mso_id": "mockIdToo",
- "mso_pass": "1491DE07AC9D716A7966BB8C2848F031",
- "admin_tenant": "service",
- "member_role": "admin",
- "tenant_metadata": true,
- "identity_server_type": "KEYSTONE",
- "identity_authentication_type": "USERNAME_PASSWORD"
- }
-
- },
- "cloud_sites":
- {
- "MT":
- {
- "region_id": "regionOne",
- "clli": "MT",
- "aic_version": "2.5",
- "identity_service_id": "MT_KEYSTONE"
- },
- "DAN":
- {
- "region_id": "RegionOne",
- "clli": "DAN",
- "aic_version": "2.5",
- "identity_service_id": "DAN_KEYSTONE"
- },
- "MTINJVCC101":
- {
- "region_id": "regionTwo",
- "clli": "MTINJVCC101",
- "aic_version": "2.5",
- "identity_service_id": "MTINJVCC101_DCP"
- },
- "MTSNJA4LCP1":
- {
- "region_id": "mtsnjlcp1",
- "clli": "MTSNJA4LCP1",
- "aic_version": "2.5",
- "identity_service_id": "MTSNJA3DCP1"
- }
-
- }
-}
-}
-
-
-
-
diff --git a/adapters/mso-adapter-utils/src/test/resources/cloud_config_bad.json b/adapters/mso-adapter-utils/src/test/resources/cloud_config_bad.json
deleted file mode 100644
index 186b6c3aa0..0000000000
--- a/adapters/mso-adapter-utils/src/test/resources/cloud_config_bad.json
+++ /dev/null
@@ -1,31 +0,0 @@
-{ "cloud_config": {
- "identity_services":
- {
- "MT_KEYSTONE":
- {
- "identity_url": "http://localhost:5000/v2.0",
- "mso_id": "john",
- "mso_pass": "FD205490A48D48475607C36B9AD902BF",
- "admin_tenant": "admin",
- "member_role": "_member_",
- "tenant_metadata": false,
- "identity_server_type": "KEYSTONE",
- "identity_authentication_type": "RACKSPACE_APIKEY"
- }
- },
- "cloud_sites":
- {
- "MT":
- {
- "region_id": "regionOne",
- "clli": "MT",
- "aic_version": "2.5",
- "identity_service_id": "MT_KEYSTONE_NOT_EXISTING"
- }
- }
-}
-}
-
-
-
-
diff --git a/adapters/mso-adapter-utils/src/test/resources/logback-test.xml b/adapters/mso-adapter-utils/src/test/resources/logback-test.xml
index d2c17192ea..3873b2c509 100644
--- a/adapters/mso-adapter-utils/src/test/resources/logback-test.xml
+++ b/adapters/mso-adapter-utils/src/test/resources/logback-test.xml
@@ -37,8 +37,12 @@
</logger>
<logger name="com.att.eelf.error" level="trace" additivity="false">
- <appender-ref ref="STDOUT" />
+ <appender-ref ref="STDOUT" />
</logger>
+ <logger name="org.onap" level="${so.log.level:-DEBUG}"
+ additivity="false">
+ <appender-ref ref="STDOUT" />
+ </logger>
<root level="info">
<appender-ref ref="STDOUT" />