Add sample for customer-show 25/20825/1
authorKanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
Thu, 26 Oct 2017 14:49:17 +0000 (20:19 +0530)
committerKanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
Thu, 26 Oct 2017 14:49:17 +0000 (20:19 +0530)
CLI-57

Change-Id: I8d67cae33d83d9ba375a32ea2fdfd34218c31ddd
Signed-off-by: Kanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-sample-1.1.yaml [deleted file]
plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-moco.json [new file with mode: 0644]
plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-sample.yaml [new file with mode: 0644]

diff --git a/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-sample-1.1.yaml b/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-sample-1.1.yaml
deleted file mode 100644 (file)
index 8c2e8db..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-onap_cli_sample_version: 1.0
-
-name: customer-show
-version: onap-1.1
-samples:
-    sample1:
-        name: Show complete details of a customer
-        input: -h https://locahost:8443 -u AAI -p AAI -x example-global-customer-id-val-8741 --long
-        output: |
-            +--------------------------------------+----------------------------------+------------------+------------------------------------+
-            |name                                  |subscriber-name                   |resource-version  |subscriber-type                     |
-            +--------------------------------------+----------------------------------+------------------+------------------------------------+
-            |example-global-customer-id-val-8741   |example-subscriber-name-val-2447  |1504017436899     |example-subscriber-type-val-24368   |
-            +--------------------------------------+----------------------------------+------------------+------------------------------------+
-    sample2:
-        name: Show basic details of a customer
-        input: -h https://locahost:8443 -u AAI -p AAI -x example-global-customer-id-val-8741
-        output: |
-            +--------------------------------------+----------------------------------+
-            |name                                  |subscriber-name                   |
-            +--------------------------------------+----------------------------------+
-            |example-global-customer-id-val-8741   |example-subscriber-name-val-2447  |
-            +--------------------------------------+----------------------------------+
diff --git a/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-moco.json b/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-moco.json
new file mode 100644 (file)
index 0000000..242db8c
--- /dev/null
@@ -0,0 +1,23 @@
+[ {
+  "request" : {
+    "method" : "get",
+    "uri" : "/aai/v11/business/customers/customer/kanag",
+    "headers" : {
+      "Authorization" : "Basic QUFJOkFBSQ==",
+      "X-FromAppId" : "onap-cli",
+      "Accept" : "application/json",
+      "X-TransactionId" : "req-95e5eac5-6839-49f3-8f9e-786789e69c67",
+      "Content-Type" : "application/json"
+    },
+    "json" : null
+  },
+  "response" : {
+    "status" : 200,
+    "json" : {
+      "global-customer-id" : "kanag",
+      "subscriber-name" : "kanag",
+      "subscriber-type" : "INFRA",
+      "resource-version" : "1509029007060"
+    }
+  }
+} ]
\ No newline at end of file
diff --git a/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-sample.yaml b/plugins/aai/src/test/resources/onap-cli-sample/customer/customer-show-schema-1.1-sample.yaml
new file mode 100644 (file)
index 0000000..1e1ba42
--- /dev/null
@@ -0,0 +1,14 @@
+onap_cli_sample_version: 1.0
+name: customer-show
+version: onap-1.1
+samples:
+  sample1:
+    name: customer-show
+    input: --customer-name kanag --long
+    moco: customer-show-schema-1.1-moco.json
+    ouput: |
+      +--------+------------------+------------------+------------------+
+      |name    |subscriber-name   |resource-version  |subscriber-type   |
+      +--------+------------------+------------------+------------------+
+      |kanag   |kanag             |1509029007060     |INFRA             |
+      +--------+------------------+------------------+------------------+