Ask Your Question

Does tempest have its own api support or it just call the openstack api when the python code is executed from git repository ?

asked 2015-12-20 22:52:03 -0600

Jagan Prakash gravatar image

updated 2015-12-21 07:01:29 -0600

Vinoth gravatar image

I have installed tempest in my OpenStack setup following this link and its running successfully while executing the command

testr run --parallel .

And I can see the log in the appropriate openstack service api's while running the above command.

But I didn't see any dedicated log files for tempest service in OpenStack. Also, I can see running the above command directly trigger the OpenStack API to run sanity test.

Is there any API support available for the tempest service, so that I can run tempest using RESTApi also.



edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted

answered 2015-12-28 03:25:17 -0600

xiangfei-ma gravatar image

Tempest supports the REST API with JSON or XML format. It is implemented based on the “unittest2” and “nose” python test frameworks.
You can run Tempest cases like these ways:

  1. Run all cases in the specified directory (and sub directories):
    nosetests Tempest
  2. Run all cases in the specified file:
    nosetests tempest/tempest/api/compute/flavors/
  3. Run all cases in the specified class:
    nosetests tempest/tempest/api/compute/flavors/
  4. Run the specified function:
    nosetests tempest/tempest/api/compute/flavors/

Hope it helps.
BTW, Nose recognizes test cases form source files, directories or packages automatically. Any classes, functions, files, directories or sub classes that match the regular expression: (?:^|[b_.-])[Tt]est will be identified and executed.
You can also write your own test cases by following the guide:

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2015-12-20 22:52:03 -0600

Seen: 111 times

Last updated: Dec 28 '15