Chapter 2. OpenStack Integration Test Suite Tests
The OpenStack Integration Test Suite has many applications. It acts as a gate for commits to the OpenStack core projects, it can stress test to generate load on a cloud deployment, and it can perform CLI tests to check the response formatting of the command line. However, the functionality that we are concerned with are the scenario tests and API tests. These tests are run against your OpenStack cloud deployment. The following sections briefly describe each of these tests and how you can implement them.
2.1. Scenario Tests
Scenario tests simulate a typical end user action workflow to test the integration points between services. The testing framework conducts the set up, tests the integration between services, and then it is torn down. You should tag the tests with which services they relate to, to make it clear which client libraries the test uses. A scenario is based on a use case, for example:
- Upload an image to the Image Service
- Deploy an instance from the image
- Attach a volume to the instance
- Create a snapshot of the instance
- Detach the volume from the instance
2.2. API Tests
API tests validate the OpenStack API. Tests use the OpenStack Integration Test Suite implementation of the OpenStack API. Both valid and invalid JSON can be used to make sure error responses are valid. Tests can be run independently, and do not rely on the state left by the previous test.