MCPcopy Index your code
hub / github.com/python/cpython / run

Method run

Lib/test/test_email/test_email.py:3537–3545  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3535 # Test make_msgid uniqueness, even with multiple threads
3536 class MsgidsThread(Thread):
3537 def run(self):
3538 # generate msgids for 3 seconds
3539 self.msgids = []
3540 append = self.msgids.append
3541 make_msgid = utils.make_msgid
3542 clock = time.monotonic
3543 tfin = clock() + 3.0
3544 while clock() < tfin:
3545 append(make_msgid(domain='testdomain-string'))
3546
3547 threads = [MsgidsThread() for i in range(5)]
3548 with threading_helper.start_threads(threads):

Callers

nothing calls this directly

Calls 1

make_msgidFunction · 0.85

Tested by

no test coverage detected