Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

nosetests: no module named tempest

I've created a virtual environment using ./ in the tempest directory in /opt/stack/tempest/. Then, I activate the virtual environment by running ./venv/bin/activate.

When I run any test, for example,

(.venv)root@ubuntu:/opt/stack/tempest# nosetests -vx

I get this error

Failure: ImportError (No module named tempest_lib) ... ERROR

ERROR: Failure: ImportError (No module named tempest_lib)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/nose/", line 411, in loadTestsFromName
    addr.filename, addr.module)
  File "/usr/lib/python2.7/dist-packages/nose/", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/usr/lib/python2.7/dist-packages/nose/", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/opt/stack/tempest/tempest_test/tempest/tempest/api/identity/admin/v3/", line 16, in <module>
    from tempest.api.identity import base
  File "/opt/stack/tempest/tempest_test/tempest/tempest/api/identity/", line 17, in <module>
    from tempest_lib import exceptions as lib_exc
ImportError: No module named tempest_lib

Ran 1 test in 0.001s

FAILED (errors=1)

Any idea why it's failing?