Running with "<span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"> ./run_tests.sh -N nova.tests.test_libvirt" works just fine, however i don't know if this is enough to get it past jenkins :/</span><br>
<br><div class="gmail_quote">On Mon, Jul 2, 2012 at 3:26 PM, Daniel P. Berrange <span dir="ltr"><<a href="mailto:berrange@redhat.com" target="_blank">berrange@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Mon, Jul 02, 2012 at 01:43:31PM +0100, Leander Bessa Beernaert wrote:<br>
> So, if no system packages can be imported, how do you test the "connection"<br>
> class for the libvirt driver?<br>
><br>
> How does that particular test case wrap around the fact that it requires<br>
> the libvirt module? The only thing i could find are these lines of code in<br>
> the driver's __init__ method. Do these somehow detect if this is a unit<br>
> test environment and import the fakelibvirt driver instead? I'm no expert<br>
> in python so i'm not sure what's happening there :s<br>
><br>
> > global libvirt<br>
> > if libvirt is None:<br>
> >     libvirt = __import__('libvirt')<br>
<br>
</div>If you have installed all the neccessary python packages on your<br>
local host, then it is entirely possible to run the Nova test<br>
suites without using virtualenv. You just need to pass the '-N'<br>
arg to the run_tests.sh script, eg on my Fedora 17 host, I can<br>
run<br>
<br>
   ./run_tests.sh -N nova.tests.test_libvirt<br>
<br>
Regards,<br>
Daniel<br>
<span class="HOEnZb"><font color="#888888">--<br>
|: <a href="http://berrange.com" target="_blank">http://berrange.com</a>      -o-    <a href="http://www.flickr.com/photos/dberrange/" target="_blank">http://www.flickr.com/photos/dberrange/</a> :|<br>
|: <a href="http://libvirt.org" target="_blank">http://libvirt.org</a>              -o-             <a href="http://virt-manager.org" target="_blank">http://virt-manager.org</a> :|<br>
|: <a href="http://autobuild.org" target="_blank">http://autobuild.org</a>       -o-         <a href="http://search.cpan.org/~danberr/" target="_blank">http://search.cpan.org/~danberr/</a> :|<br>
|: <a href="http://entangle-photo.org" target="_blank">http://entangle-photo.org</a>       -o-       <a href="http://live.gnome.org/gtk-vnc" target="_blank">http://live.gnome.org/gtk-vnc</a> :|<br>
</font></span></blockquote></div><br>