Unit testing multiprocessing code on Windows

Discussion in 'Python' started by Matt Chaput, Feb 17, 2011.

  1. Matt Chaput

    Matt Chaput Guest

    Does anyone know the "right" way to write a unit test for code that uses
    multiprocessing on Windows?

    The problem is that with both "python setup.py tests" and "nosetests",
    when they get to a multiprocessing test they spawn multiple copies of
    the testing suite. The test runner in PyDev works properly.

    Maybe multiprocessing is starting new Windows processes by copying the
    command line of the current process, but if the command line is
    "nosetests", it's a one way ticket to an infinite explosion of processes.

    Any thoughts?

    Thanks,

    Matt
    Matt Chaput, Feb 17, 2011
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matt Chaput
    Replies:
    0
    Views:
    216
    Matt Chaput
    Feb 17, 2011
  2. Ulrich Eckhardt

    unit-profiling, similar to unit-testing

    Ulrich Eckhardt, Nov 16, 2011, in forum: Python
    Replies:
    6
    Views:
    328
    Roy Smith
    Nov 18, 2011
  3. Bill Mosteller
    Replies:
    0
    Views:
    223
    Bill Mosteller
    Oct 22, 2009
  4. Avi
    Replies:
    0
    Views:
    491
  5. Avi
    Replies:
    0
    Views:
    463
Loading...

Share This Page