Thanks, that let me see the real problem now:<div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">./tools/with_venv.sh nosetests -svx nova<br>
nose.config: INFO: Set working dir to /home/gsd/nova/nova/tests<br>nose.config: INFO: Working directory /home/gsd/nova/nova/tests is a package; adding to sys.path<br>nose.config: INFO: Ignoring files matching ['^\\.', '^_', '^setup\\.py$']<br>
nose.plugins.cover: INFO: Coverage report will include only packages: ['nova']<br>nose.selector: INFO: /home/gsd/nova/nova/auth/opendj.sh is executable; skipped<br>nose.selector: INFO: /home/gsd/nova/nova/auth/slap.sh is executable; skipped<br>
nose.selector: INFO: /home/gsd/nova/nova/cloudpipe/bootscript.template is executable; skipped<br>Failure: ImportError (No module named libvirt) ... ERROR<br>======================================================================<br>
ERROR: Failure: ImportError (No module named libvirt)<br>----------------------------------------------------------------------<br>Traceback (most recent call last):<br>  File "/home/gsd/nova/.venv/local/lib/python2.7/site-packages/nose/loader.py", line 390, in loadTestsFromName<br>
    addr.filename, addr.module)<br>  File "/home/gsd/nova/.venv/local/lib/python2.7/site-packages/nose/importer.py", line 39, in importFromPath<br>    return self.importFromDir(dir_path, fqname)<br>  File "/home/gsd/nova/.venv/local/lib/python2.7/site-packages/nose/importer.py", line 86, in importFromDir<br>
    mod = load_module(part_fqname, fh, filename, desc)<br>  File "/home/gsd/nova/nova/test.py", line 41, in <module><br>    from nova.tests import fake_flags<br>  File "/home/gsd/nova/nova/tests/fake_flags.py", line 24, in <module><br>
    flags.DECLARE('compute_scheduler_driver', 'nova.scheduler.multi')<br>  File "/home/gsd/nova/nova/flags.py", line 52, in DECLARE<br>    __import__(module_string, globals(), locals())<br>  File "/home/gsd/nova/nova/scheduler/multi.py", line 27, in <module><br>
    from nova.scheduler import driver<br>  File "/home/gsd/nova/nova/scheduler/driver.py", line 53, in <module><br>    flags.DECLARE('libvirt_type', 'nova.virt.libvirt.connection')<br>  File "/home/gsd/nova/nova/flags.py", line 52, in DECLARE<br>
    __import__(module_string, globals(), locals())<br>  File "/home/gsd/nova/nova/virt/libvirt/connection.py", line 73, in <module><br>    from nova.virt.libvirt import diagnostics as libvirt_diagnostics<br>
  File "/home/gsd/nova/nova/virt/libvirt/diagnostics.py", line 75, in <module><br>    import libvirt as virt<br>ImportError: No module named libvirt<br>----------------------------------------------------------------------<br>
Ran 1 test in 0.002s<br>FAILED (errors=1)</blockquote></div><div><br></div><div><div>Libvirt is present on my system, i can import it through the python interpreter from any location. Yet, it still says it is not present. Could this have to do with the virtual_env or fakelibvirt?</div>
<div><br><div class="gmail_quote">On Fri, Jun 29, 2012 at 6:54 PM, Jay Pipes <span dir="ltr"><<a href="mailto:jaypipes@gmail.com" target="_blank">jaypipes@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Leander,<br>
<br>
I've noticed some weirdness with the openstack.nose_plugin (which is used by default for the Nova test runner) sometimes either throwing errors (particularly errors raised by nosetests) away and/or coming up with a different set of skip tests than when running just with nosetests.<br>

<br>
So, I'd recommend running just this:<br>
<br>
./tools/with_venv.sh nosetests -svx nova<br>
<br>
That will stop at the first error and probably will give you better insight into the actual errors that are likely being suppressed by the openstack nose plugin.<br>
<br>
best,<br>
-jay<div class="im"><br>
<br>
On 06/29/2012 09:02 AM, Leander Bessa Beernaert wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
Hello,<br>
<br>
I'm sorry to restart the topic<br>
(<a href="https://lists.launchpad.net/openstack/msg13621.html" target="_blank">https://lists.launchpad.net/<u></u>openstack/msg13621.html</a>), but<br>
i accidentally deleted the message in my inbox :S.<br>
<br>
I'm still having the same problem, each time i add "import libvirt" to<br>
the file "diangostics.py" (<a href="https://review.openstack.org/#/c/8839/" target="_blank">https://review.openstack.org/<u></u>#/c/8839/</a>) the<br>
entire test suit won't run.<br>
<br></div>
*With the import* present i get the following output:<div class="im"><br>
<br>
      ------------------------------<u></u>------------------------------<u></u>----------<br>
    Ran 0 tests in 0.000s<br>
    OK Running PEP8 and HACKING compliance check...<br>
    2 imports missing in this test environment<br>
<br>
<br></div>
*Without the import *present it get this output:<div class="im"><br>
<br>
      ------------------------------<u></u>------------------------------<u></u>----------<br>
    Ran 3030 tests in 233.326s<br>
    OK (SKIP=22) Running PEP8 and HACKING compliance check...<br>
    11 imports missing in this test environment<br>
<br>
<br>
<br>
The problem now is that, according to the OpenStack conventions, the<br>
import must be present. However, with the import present i can't get any<br>
of the tests to run.<br>
I'm no expert in Python, so could someone please help me out here?<br>
<br>
Regards,<br>
<br>
Leander<br>
<br>
<br></div>
______________________________<u></u>_________________<br>
Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~<u></u>openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~<u></u>openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/<u></u>ListHelp</a><br>
<br>
</blockquote>
<br>
<br>
______________________________<u></u>_________________<br>
Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~<u></u>openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~<u></u>openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/<u></u>ListHelp</a><br>
</blockquote></div><br></div></div>