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

Method test_recursion

Lib/test/_test_multiprocessing.py:712–730  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

710
711 @warnings_helper.ignore_fork_in_thread_deprecation_warnings()
712 def test_recursion(self):
713 rconn, wconn = self.Pipe(duplex=False)
714 self._test_recursion(wconn, [])
715
716 time.sleep(DELTA)
717 result = []
718 while rconn.poll():
719 result.append(rconn.recv())
720
721 expected = [
722 [],
723 [0],
724 [0, 0],
725 [0, 1],
726 [1],
727 [1, 0],
728 [1, 1]
729 ]
730 self.assertEqual(result, expected)
731
732 @classmethod
733 def _test_sentinel(cls, event):

Callers

nothing calls this directly

Calls 7

_test_recursionMethod · 0.95
PipeMethod · 0.80
sleepMethod · 0.45
pollMethod · 0.45
appendMethod · 0.45
recvMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected