<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#ffffff">
    To get coverage measurement of subprocesses, you need to take some
    extra steps, unless I'm missing something you're doing in the
    description below.&nbsp; Are both servers started with Popen?&nbsp; And one is
    measured and the other is not?&nbsp; You can check on measurement with
    the "coverage debug data" command, which will show you a summary of
    the data collected during the last run.<br>
    <br>
    There's a page in the docs about getting subprocesses measured:
    <a class="moz-txt-link-freetext" href="http://nedbatchelder.com/code/coverage/subprocess.html">http://nedbatchelder.com/code/coverage/subprocess.html</a><br>
    <br>
    --Ned.<br>
    <br>
    On 7/19/2011 6:25 PM, Joesan Gabaldon wrote:
    <blockquote
cite="mid:CAPfGs70tiY9Fmw24ix9ftQWZ73tjkbGWS_4GqYuKm43pFBKV-g@mail.gmail.com"
      type="cite">Hey all, I've been trying to figure this out on and
      off for a couple months now (it hasn't really been priority until
      recently) and I could really use some help fixing this.<br>
      <br>
      I'm running a system which requires 2 serves to run, one of them
      being a pylons project.&nbsp; For some reason coverage doesn't seem to
      be checking any of the files in the pylons server.&nbsp; I have a
      script which launches both servers using Popen, with the pylons
      server launched with the shell command "paster serve
      development.ini".&nbsp; <br>
      <br>
      Nosetests &amp; coverage are launched with:<br>
      <br>
      &nbsp;&nbsp;&nbsp; nosetests -v thisproject/tests_folder --with-coverage
      --with-xunit --xunit-file=./nosetests.xml<br>
      &nbsp;&nbsp;&nbsp; coverage xml --include=thisproject/*
      --omit=./thisproject/tests_folder/* <br>
      <br>
      I've also tried explicitly telling the coverage report to include
      the pylons folder which is located at
      "thisproject/clients/pylons_server":<br>
      <br>
      &nbsp;&nbsp;&nbsp; coverage xml
      --include=thisproject/*,thisproject/clients/pylons_server
      --omit=./thisproject/tests_folder/* <br>
      <br>
      But that doesn't seem to work, I suspect because that folder is
      never even executed when nosetests is running the tests.&nbsp; The
      functions are definitely getting executed though as those tests
      pass, and other files in the clients folder and subdirectories of
      clients are getting included in the coverage report.&nbsp; Anyone have
      any ideas?<br>
      <br>
      Joesan<br>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
testing-in-python mailing list
<a class="moz-txt-link-abbreviated" href="mailto:testing-in-python@lists.idyll.org">testing-in-python@lists.idyll.org</a>
<a class="moz-txt-link-freetext" href="http://lists.idyll.org/listinfo/testing-in-python">http://lists.idyll.org/listinfo/testing-in-python</a>
</pre>
    </blockquote>
  </body>
</html>