Permalink
Browse files

Fixed worker_pids test case.

  • Loading branch information...
1 parent 062b548 commit e119d7ed117267674eb3ead8d65caeb9b4d9c949 @lcwill lcwill committed Jan 22, 2013
Showing with 3 additions and 3 deletions.
  1. +3 −3 tests/test_worker.py
@@ -311,13 +311,13 @@ def test_worker_pids(self):
os.waitpid(pid, 0)
# ensure worker_pids() returned the correct pids
- assert len(worker_pids) == len(pids)
for pid in pids:
assert str(pid) in worker_pids
- # ensure there are no longer any workers running
+ # ensure the workers are no longer returned by worker_pids()
worker_pids = Worker.worker_pids()
- assert len(worker_pids) == 0
+ for pid in pids:
+ assert str(pid) not in worker_pids
def spawn_worker(self, queues):
pid = os.fork()

0 comments on commit e119d7e

Please sign in to comment.