<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Oct 6, 2015 at 10:51 AM, Antoine Pitrou <span dir="ltr"><<a href="mailto:solipsis@pitrou.net" target="_blank">solipsis@pitrou.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div id=":12x" class="" style="overflow:hidden">They should be inside the module. That way, you can check an installed<br>
module is ok by running e.g. "python -m mypackage.tests". Any other<br>
choice makes testing installed modules more cumbersome.</div></blockquote></div><br><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">​Does that really make sense? I haven't heard of any user actually running tests​<br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">that way. To be honest I haven't ever ran Python's own tests suite as part <br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">of a user installation.<br><br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">​I've seen some projects that lump up lots of test data and crazy files in their <br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">packages tests and that created install issues​ (Pelican is one example, pretty sure<br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">there are others).<br><br>On the other hand, if the user really wants to run the tests he can just get <br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">the sources (that would naturally include everything)?<br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif"><br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">Seems odd to suggest something is a best practice without giving any clue of how<br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">test dependencies would be managed. Just because CPython does it doesn't mean<br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">libraries should.<br></div><br><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div><span style="font-family:trebuchet ms,sans-serif"><span style="color:rgb(51,51,51)"><br><font size="2"><span style="color:rgb(51,51,51)">Thanks,</span><br><span style="color:rgb(153,153,153)">-- Ionel</span></font></span><font size="2"><font style="color:rgb(153,153,153)"> Cristian Mărieș, <a href="http://blog.ionelmc.ro" target="_blank">http://blog.ionelmc.ro</a><br></font></font></span></div></div></div></div></div></div></div>
</div></div>