Skip to content

Instantly share code, notes, and snippets.

@martijnthe
Created February 8, 2015 23:32
Show Gist options
  • Save martijnthe/b2d778b00bf84c9b7198 to your computer and use it in GitHub Desktop.
Save martijnthe/b2d778b00bf84c9b7198 to your computer and use it in GitHub Desktop.
unittest vs threading helper
import threading
def wait_until_all_threads_finish():
all_threads = threading.enumerate()
all_threads.remove(threading.current_thread())
for t in all_threads:
t.join()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment