diff options
author | Kanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com> | 2017-10-27 10:14:58 +0530 |
---|---|---|
committer | Kanagaraj Manickam <kanagaraj.manickam@huawei.com> | 2017-10-27 04:53:05 +0000 |
commit | 31fcc8994ccd8ad0fe1f9cd2b248e80e7c49136e (patch) | |
tree | 7cadf7e5eac4b51a86bc18c6d8bdd4dd468da5d3 | |
parent | e74171b29d3cdf3ed50796138ea67561ec624f43 (diff) |
Add sample for subscription-list
CLI-57
Change-Id: I591410ed12c5b075b623cefe8b994c5337aef96a
Signed-off-by: Kanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
3 files changed, 57 insertions, 25 deletions
diff --git a/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-sample-1.1.yaml b/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-sample-1.1.yaml deleted file mode 100644 index 98880aad..00000000 --- a/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-sample-1.1.yaml +++ /dev/null @@ -1,25 +0,0 @@ -onap_cli_sample_version: 1.0 - -name: subscription-list -version: onap-1.1 -samples: - sample1: - name: List the configured subscription in onap for a given customer - input: -h https://locahost:8443 -u AAI -p AAI -x customer-4 - output: | - +--------------+------------------+ - |service-type |resource-version | - +--------------+------------------+ - |vTest |1504258356743 | - +--------------+------------------+ - - - sample2: - name: List the configured subscription in onap for a given customer with complete details - input: -h https://locahost:8443 -u AAI -p AAI -x customer-4 --long - output: | - +--------------+------------------+--------------------------------------+----------+----------+ - |service-type |resource-version |tenant |region |cloud | - +--------------+------------------+--------------------------------------+----------+----------+ - |vTest |1505276255854 |3853ca3c-3bc3-4500-9ddf-08e8cca5493f |region-1 |cloud-1 | - +--------------+------------------+--------------------------------------+----------+----------+ diff --git a/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-moco.json b/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-moco.json new file mode 100644 index 00000000..a70ce4e0 --- /dev/null +++ b/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-moco.json @@ -0,0 +1,43 @@ +[ {
+ "request" : {
+ "method" : "get",
+ "uri" : "/aai/v11/business/customers/customer/kanag/service-subscriptions",
+ "headers" : {
+ "Authorization" : "Basic QUFJOkFBSQ==",
+ "X-FromAppId" : "onap-cli",
+ "Accept" : "application/json",
+ "X-TransactionId" : "req-fd86411d-c6ea-4af5-a4f8-2296587b832b",
+ "Content-Type" : "application/json"
+ },
+ "json" : null
+ },
+ "response" : {
+ "status" : 200,
+ "json" : {
+ "service-subscription" : [ {
+ "service-type" : "vFW-kanag",
+ "resource-version" : "1509079144326",
+ "relationship-list" : {
+ "relationship" : [ {
+ "related-to" : "tenant",
+ "related-link" : "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/huawei-cloud/bangalore/tenants/tenant/e18173e6-6a13-4614-a13c-3859e7321103",
+ "relationship-data" : [ {
+ "relationship-key" : "cloud-region.cloud-owner",
+ "relationship-value" : "huawei-cloud"
+ }, {
+ "relationship-key" : "cloud-region.cloud-region-id",
+ "relationship-value" : "bangalore"
+ }, {
+ "relationship-key" : "tenant.tenant-id",
+ "relationship-value" : "e18173e6-6a13-4614-a13c-3859e7321103"
+ } ],
+ "related-to-property" : [ {
+ "property-key" : "tenant.tenant-name",
+ "property-value" : "kanag-tenant"
+ } ]
+ } ]
+ }
+ } ]
+ }
+ }
+} ]
\ No newline at end of file diff --git a/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-sample.yaml b/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-sample.yaml new file mode 100644 index 00000000..d4c17de5 --- /dev/null +++ b/plugins/aai/src/test/resources/onap-cli-sample/subscription/subscription-list-schema-1.1-sample.yaml @@ -0,0 +1,14 @@ +onap_cli_sample_version: 1.0 +name: subscription-list +version: onap-1.1 +samples: + sample1: + name: subscription-list + input: --customer-name kanag + moco: subscription-list-schema-1.1-moco.json + ouput:| + +--------------+------------------+ + |service-type |resource-version | + +--------------+------------------+ + |vFW-kanag |1509079144326 | + +--------------+------------------+ |