MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_action

Method test_action

Lib/test/_test_multiprocessing.py:2124–2131  ·  view source on GitHub ↗

Test the 'action' callback

(self)

Source from the content-addressed store, hash-verified

2122 raise RuntimeError
2123
2124 def test_action(self):
2125 """
2126 Test the 'action' callback
2127 """
2128 results = self.DummyList()
2129 barrier = self.Barrier(self.N, action=AppendTrue(results))
2130 self.run_threads(self._test_action_f, (barrier, results))
2131 self.assertEqual(len(results), 1)
2132
2133 @classmethod
2134 def _test_abort_f(cls, barrier, results1, results2):

Callers

nothing calls this directly

Calls 6

DummyListMethod · 0.95
run_threadsMethod · 0.95
AppendTrueClass · 0.85
lenFunction · 0.85
BarrierMethod · 0.80
assertEqualMethod · 0.45

Tested by

no test coverage detected