Fix README 61/114761/3
authormrichomme <morgan.richomme@orange.com>
Tue, 10 Nov 2020 13:31:14 +0000 (14:31 +0100)
committermrichomme <morgan.richomme@orange.com>
Tue, 10 Nov 2020 14:54:08 +0000 (15:54 +0100)
- " missing
- latest referenced instead of latest
- detail interactive mode
- precise how to run only a subset of the tests

Issue-ID: TEST-274

Signed-off-by: mrichomme <morgan.richomme@orange.com>
Change-Id: Id28ea0a4602a903eb4ff28bb7671737fa7d58b50
Signed-off-by: mrichomme <morgan.richomme@orange.com>
infra-healthcheck/README.md
security/README.md
smoke-usecases-pythonsdk/README.md

index 97ed02e..117bd96 100644 (file)
@@ -82,6 +82,45 @@ nexus3.onap.org:10003/onap/xtesting-infra-healthcheck:master
 /bin/bash -c "run_tests -r -t all"
 ```
 
+Note that you can run only a subset of the tests and decide if you report the
+results to the test BD or not.
+The following commands are correct:
+
+```
+docker run -v <the kube config>:/root/.kube/config
+-v <result directory>:/var/lib/xtesting/results
+nexus3.onap.org:10003/onap/xtesting-infra-healthcheck:master
+/bin/bash -c "run_tests -t onap-k8s"
+```
+
+```
+docker run -v <the kube config>:/root/.kube/config
+-v <the user home dir>/.helm/plugins/deploy/cache/onap/logs:/onap_helm_logs
+-v <result directory>:/var/lib/xtesting/results
+nexus3.onap.org:10003/onap/xtesting-infra-healthcheck:master
+/bin/bash -c "run_tests -r -t onap-helm"
+```
+
+You can also run the docker in interactive mode, so you can run the tests from
+inside the docker and directly modify the code of the test if you want.
+
+```
+docker run -it -v <the kube config>:/root/.kube/config
+-v <the user home dir>/.helm/plugins/deploy/cache/onap/logs:/onap_helm_logs
+-v <result directory>:/var/lib/xtesting/results
+nexus3.onap.org:10003/onap/xtesting-infra-healthcheck:master bash
+```
+
+In this case you will get the bash prompt, you can run the test by typing in
+the console
+
+```
+# run_tests -t onap-k8s
+```
+
+The code of the tests is in the docker. For python test, have a look at
+/usr/lib/python3.8/site-packages. See the Dockerfile for more information.
+
 ### Output
 
 ```
index 2a94f26..6821d2e 100644 (file)
@@ -45,7 +45,7 @@ You can run this docker by typing:
 ```
 docker run -v <the kube config>:/root/.kube/config -v
 <result directory>:/var/lib/xtesting/results
-nexus3.onap.org:10003/onap/xtesting-security:latest
+nexus3.onap.org:10003/onap/xtesting-security:master
 ```
 
 Options:
@@ -72,10 +72,41 @@ The command becomes:
 ```
 docker run -v <the kube config>:/root/.kube/config -v
 <result directory>:/var/lib/xtesting/results
-nexus3.onap.org:10003/onap/xtesting-security:latest
-/bin/bash -c "run_tests -r -t all
+nexus3.onap.org:10003/onap/xtesting-security:master
+/bin/bash -c "run_tests -r -t all"
 ```
 
+Note that you can run only a subset of the tests and decide if you report the
+results to the test BD or not.
+The following commands are correct:
+
+```
+docker run -v <the kube config>:/root/.kube/config -v
+<result directory>:/var/lib/xtesting/results
+nexus3.onap.org:10003/onap/xtesting-security:master
+/bin/bash -c "run_tests -t root_pods"
+```
+
+You can also run the docker in interactive mode, so you can run the tests from
+inside the docker and directly modify the code of the test if you want.
+
+```
+docker run -it -v <the kube config>:/root/.kube/config -v
+<result directory>:/var/lib/xtesting/results
+nexus3.onap.org:10003/onap/xtesting-security:master bash
+```
+
+In this case you will get the bash prompt, you can run the test by typing in
+the console
+
+```
+# run_tests -t unlimitted_pods
+```
+
+The code of the tests is in the docker. For python test, have a look at
+/usr/lib/python3.8/site-packages, for security tests they are usually located
+at /. See the Dockerfile for more information.
+
 ### Output
 
 ```
index d21f5d2..d0da26c 100644 (file)
@@ -221,7 +221,7 @@ docker run
 --add-host="sdc.workflow.plugin.simpledemo.onap.org:<your ONAP IP>"
 --add-host="sdc.dcae.plugin.simpledemo.onap.org:<your ONAP IP>"
 --add-host="msb.api.simpledemo.onap.org:<your ONAP IP>"
-nexus3.onap.org:10003/onap/xtesting-smoke-usecases-pythonsdk:latest /bin/sh -c "run_tests -t basic_vm"
+nexus3.onap.org:10003/onap/xtesting-smoke-usecases-pythonsdk:master /bin/sh -c "run_tests -t basic_vm"
 ```
 
 Unkike the other xtesting docker, 1 docker = 1 use case, the target -t all is
@@ -234,12 +234,15 @@ docker run -it
 -v <your local env>:/var/lib/xtesting/conf/env_file
 -v <cloud.yaml file corresponding to your VNF tenant>/root/.config/openstack.yaml
 -v <kube config file corresponding to your k8s cluster>/root/.kube/config
--v <service definition yaml matching your environment>:/usr/lib/python3.8/site-packages/onaptests/templates/vnf-services/ubuntu16test-service.yaml
 -v <result directory>:/var/lib/xtesting/results
-nexus3.onap.org:10003/onap/xtesting-smoke-usecases-pythonsdk:latest sh
+nexus3.onap.org:10003/onap/xtesting-smoke-usecases-pythonsdk:master sh
 ```
 
 Inside the docker you can edit the /etc/hosts and indicate the different hosts).
+You can also edit the configuration file
+/usr/lib/python3.8/site-packages/onaptests/templates/vnf-services/ubuntu16test-service.yaml.
+You can also edit the tester and test settings in
+/usr/lib/python3.8/site-packages/onaptests.
 Then you can run the test with the following command:
 
 ```