Hey Ravi,
Cool, and how do you run (say) only test_reboot_server_hard from
ServerActionsTestBase ?
Whenever I try, I get;
stack@DevStack:~/tempest$ nosetests -sv
tempest.tests.compute.servers.test_server_actions.py:ServerActionsTestBase.test_reboot_server_hard
The server should be power cycled ... ERROR
======================================================================
ERROR: The server should be power cycled
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/lib/pymodules/python2.7/nose/case.py", line 371, in setUp
try_run(self.inst, ('setup', 'setUp'))
File "/usr/lib/pymodules/python2.7/nose/util.py", line 478, in try_run
return func()
File
"/opt/stack/tempest/tempest/tests/compute/servers/test_server_actions.py",
line 39, in setUp
resp, server = self.client.create_server(self.name,
AttributeError: 'ServerActionsTestBase' object has no attribute 'client'
-------------------- >> begin captured logging << --------------------
tempest.config: INFO: Using tempest config file
/opt/stack/tempest/etc/tempest.conf
tempest.tests.compute: DEBUG: Entering tempest.tests.compute.setup_package
--------------------- >> end captured logging << ---------------------
On 11/09/2012 07:16 PM, Venkatesan, Ravikumar wrote:
Test_server_actions.py
~/openstack_projects/tempest$ nosetests -sv
tempest/tests/compute/servers/test_server_actions.py
The server's password should be set to the provided password ...
SKIP: Change password not available.
Negative Test: The server reboot on non existent server should return
... ok
The server should be power cycled ... ok
The server should be signaled to reboot gracefully ... SKIP: Until
bug 1014647 is dealt with.
Negative test: The server rebuild for a non existing server should
not ... ok
The server should be rebuilt using the provided image and data ... ok
The server's RAM and disk space should be modified to that of ...
SKIP: Resize not available.
The server's RAM and disk space should return to its original ...
SKIP: Resize not available.
The server's password should be set to the provided password ...
SKIP: Change password not available.
Negative Test: The server reboot on non existent server should return
... ok
The server should be power cycled ... ok
The server should be signaled to reboot gracefully ... SKIP: Until
bug 1014647 is dealt with.
Negative test: The server rebuild for a non existing server should
not ... ok
The server should be rebuilt using the provided image and data ... ok
The server's RAM and disk space should be modified to that of ...
SKIP: Resize not available.
The server's RAM and disk space should return to its original ...
SKIP: Resize not available.
----------------------------------------------------------------------
Ran 16 tests in 127.553s
OK (SKIP=8)
Regards,
Ravi
*From:*openstack-bounces+ravikumar.venkatesan=hp.com@xxxxxxxxxxxxxxxxxxx
[mailto:openstack-bounces+ravikumar.venkatesan=hp.com@xxxxxxxxxxxxxxxxxxx]
*On Behalf Of *Venkatesan, Ravikumar
*Sent:* Friday, November 09, 2012 4:13 PM
*To:* Stef T; openstack@xxxxxxxxxxxxxxxxxxx
*Subject:* Re: [Openstack] [Tempest] unable to run subset of tests
via nosetests
To run a single test from Tempest:
~/openstack_projects/tempest$ nosetests -sv
tempest/tests/compute/flavors/test_flavors.py
The expected flavor details should be returned ... ok
Ensure 404 returned for non-existant flavor ID ... ok
flavor details are not returned for non existant flavors ... ok
List of all flavors should contain the expected flavor ... ok
The detailed list of flavors should be filtered by disk space ... ok
The detailed list of flavors should be filtered by RAM ... ok
Only the expected number of flavors (detailed) should be returned ... ok
The list of flavors should start from the provided marker ... ok
The list of flavors should be filtered by disk space ... ok
The list of flavors should be filtered by RAM ... ok
Only the expected number of flavors should be returned ... ok
The list of flavors should start from the provided marker ... ok
Detailed list of all flavors should contain the expected flavor ... ok
The expected flavor details should be returned ... ok
Ensure 404 returned for non-existant flavor ID ... ok
flavor details are not returned for non existant flavors ... ok
List of all flavors should contain the expected flavor ... ok
The detailed list of flavors should be filtered by disk space ... ok
The detailed list of flavors should be filtered by RAM ... ok
Only the expected number of flavors (detailed) should be returned ... ok
The list of flavors should start from the provided marker ... ok
The list of flavors should be filtered by disk space ... ok
The list of flavors should be filtered by RAM ... ok
Only the expected number of flavors should be returned ... ok
The list of flavors should start from the provided marker ... ok
Detailed list of all flavors should contain the expected flavor ... ok
----------------------------------------------------------------------
Ran 26 tests in 7.230s
OK
Regards,
Ravi
*From:*openstack-bounces+ravikumar.venkatesan=hp.com@xxxxxxxxxxxxxxxxxxx
<mailto:openstack-bounces+ravikumar.venkatesan=hp.com@xxxxxxxxxxxxxxxxxxx>
[mailto:openstack-bounces+ravikumar.venkatesan=hp.com@xxxxxxxxxxxxxxxxxxx]
*On Behalf Of *Stef T
*Sent:* Friday, November 09, 2012 4:06 PM
*To:* openstack@xxxxxxxxxxxxxxxxxxx
<mailto:openstack@xxxxxxxxxxxxxxxxxxx>
*Subject:* [Openstack] [Tempest] unable to run subset of tests via
nosetests
Hey Everyone,
So, I was trying to run only a single test from Tempest, and I
naively tried the usual nosetest syntax of;
nosetests -v
tempest.tests.compute.servers.test_server_actions:ServerActionsTestBase.test_resize_server_confirm
No dice, so, I then tried the slightly more bulky but still
relatively quick;
nosetests -v tempest.tests.compute.servers.test_server_actions
And I got 8 errors. I got this down to 4 by moving the
__init__.py from tempest/tests/compute into
tempest/tests/compure/servers but, this can't be right. Can it ? Is
Tempest not designed to run a single functional test or a subset ? I
find this hard to believe, and I pray I am doing something 'duh'.
Python 2.7.2, tempest -TRUNK.
Regards
S.
_______________________________________________
Mailing list: https://launchpad.net/~openstack
Post to : openstack@xxxxxxxxxxxxxxxxxxx
Unsubscribe : https://launchpad.net/~openstack
More help : https://help.launchpad.net/ListHelp