Automated Testing
Contents
Introduction
Tempest is a group of black box functional/integration tests run against a live OpenStack cluster. Tempest tests cover aspects such as API validation, scenarios, and anything else useful to help validate an OpenStack deployment.
Tempest Flow Diagram
Test Automation
The test_automation project is from Akraino Gerrit. It is to be cloned into /opt directory on the designated test node. For cloning 'git clone' command can be used and it is shown in the box below.
For the following steps, substitute appropriate values for the OpenStack username, password, region name, and desired timeout ( 1600 Seconds).
$ cd /opt
$ sudo git clone http://gerrit.akraino.org/test_automation.git
$ cd test_automation/openstack-tempest
$ sudo vi tempest/values.yaml # Edit candidate/blacklisted tests as needed
$ OS_USERNAME=test OS_PASSWORD=xyz OS_REGION_NAME=NewRegion ./test_run.sh
$ TIMEOUT=1600 ./test_status.sh # optional flag: --no-delete (use for debugging)
test_run.sh runs the Akraino Tempest Helm package. It performs the following actions:
Set default values
Validate OpenStack settings
Delete any partially deleted instances
Clean previous runs, if any, if Tempest is running
Install tempest as a pod on a given cluster, also via Helm charts
Run Tempest tests
Return 0 on success, 1 on error
Prior to running the Helm package, edit values.yaml as needed. Observe that the conf field's script key determines which group of tests are run, as well as any blacklisted tests. Unresolvable failed tests should be added to the blacklist.
test_status.sh checks the status of the Tempest Helm package and collects test results. It performs the following actions:
Set default values
Check for Tempest pod existence
Check pod status frequently
Wait for pod to complete, and abort if pod does not complete
Save logs, e.g., the default:
/tmp/results.txtCapture and display test results
Delete Tempest deployment unless
--no-deleteis specified for debugging purposesReturn 0 on success, 1 on error
Additional Test Tools (future integration)
Robot CLI: ONAP end-to-end testing
OpenStack Shaker: Tenant networking performance
OPNFV Yardstick: Infrastructure verification
Heptio Sonobuoy: End-to-end K8s conformance-testing, workload debugging, and data collection