tempest/tempest
Andrea Frittoli 486ede779b Drop OfficialClientManager and references to it
OfficialClientManager is unused now that scenario tests use
clients.Manager instead. Dropping the class, the hacking
rule that forbade its use in API tests and related unit tests.

Change-Id: Ib359b9ab0a903436d9d9c265e8c4d82bdd80a496
2014-10-01 11:27:02 +01:00
..
api Merge "Fix resource cleanup in server rescue tests" 2014-09-30 19:13:05 +00:00
api_schema Merge "Add response schema for V2 sec grp default rule" 2014-09-26 23:35:34 +00:00
cli Merge "Make cli test namespace include test files" 2014-09-20 12:51:59 +00:00
cmd javelin: Detach the volume before destruction 2014-09-29 17:20:39 -04:00
common Drop OfficialClientManager from tenant isolation 2014-10-01 11:08:43 +01:00
hacking Drop OfficialClientManager and references to it 2014-10-01 11:27:02 +01:00
openstack olso log sync 2014-07-11 08:29:53 -04:00
scenario Drop OfficialClientManager and references to it 2014-10-01 11:27:02 +01:00
services Merge "enable volumes v2 snapshot tests by sharing codes" 2014-09-29 16:42:10 +00:00
stress Replace wait with communicate to avoid potential deadlock 2014-09-23 09:37:39 -07:00
test_discover Use unittest2.TestSuite with py26 2014-01-27 10:54:44 +01:00
tests Drop OfficialClientManager and references to it 2014-10-01 11:27:02 +01:00
thirdparty Merge "Add "reboot_instance" EC2 API test" 2014-09-28 05:41:37 +00:00
README.rst Add unit test section to the field guide index 2014-07-25 16:13:10 -04:00
__init__.py Changes the namespace from storm to tempest, as well as adding addition tests and improvements 2011-12-06 16:48:03 -06:00
auth.py Enable H407,H305,H307,E122 ignore E123 2014-08-12 17:39:16 -04:00
clients.py Drop OfficialClientManager and references to it 2014-10-01 11:27:02 +01:00
config.py Updates Tempest to match Zaqar's API name change 2014-09-23 00:00:04 -03:00
exceptions.py Enable E128 ignore E129 2014-08-13 17:50:55 -04:00
manager.py Select AuthProvider type from credentials type 2014-09-17 16:34:53 +01:00
test.py Framework for resource safe class level fixtures 2014-09-18 21:05:49 +01:00

README.rst

Tempest Field Guide Overview

Tempest is designed to be useful for a large number of different environments. This includes being useful for gating commits to OpenStack core projects, being used to validate OpenStack cloud implementations for both correctness, as well as a burn in tool for OpenStack clouds.

As such Tempest tests come in many flavors, each with their own rules and guidelines. Below is the proposed Havana restructuring for Tempest to make this clear.

tempest/
   api/ - API tests
   cli/ - CLI tests
   scenario/ - complex scenario tests
   stress/ - stress tests
   thirdparty/ - 3rd party api tests

Each of these directories contains different types of tests. What belongs in each directory, the rules and examples for good tests, are documented in a README.rst file in the directory.

api_field_guide

API tests are validation tests for the OpenStack API. They should not use the existing python clients for OpenStack, but should instead use the tempest implementations of clients. This allows us to test both XML and JSON. Having raw clients also lets us pass invalid JSON and XML to the APIs and see the results, something we could not get with the native clients.

When it makes sense, API testing should be moved closer to the projects themselves, possibly as functional tests in their unit test frameworks.

cli_field_guide

CLI tests use the openstack CLI to interact with the OpenStack cloud. CLI testing in unit tests is somewhat difficult because unlike server testing, there is no access to server code to instantiate. Tempest seems like a logical place for this, as it prereqs having a running OpenStack cloud.

scenario_field_guide

Scenario tests are complex "through path" tests for OpenStack functionality. They are typically a series of steps where complicated state requiring multiple services is set up exercised, and torn down.

Scenario tests can and should use the OpenStack python clients.

stress_field_guide

Stress tests are designed to stress an OpenStack environment by running a high workload against it and seeing what breaks. The stress test framework runs several test jobs in parallel and can run any existing test in Tempest as a stress job.

third_party_field_guide -----------------------------

Many openstack components include 3rdparty API support. It is completely legitimate for Tempest to include tests of 3rdparty APIs, but those should be kept separate from the normal OpenStack validation.

unit_tests_field_guide

Unit tests are the self checks for Tempest. They provide functional verification and regression checking for the internal components of tempest. They should be used to just verify that the individual pieces of tempest are working as expected.