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

Method test_different_thread

Lib/test/lock_tests.py:292–301  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

290 self.wait_phase(phase, 2)
291
292 def test_different_thread(self):
293 # Lock can be released from a different thread.
294 lock = self.locktype()
295 lock.acquire()
296 def f():
297 lock.release()
298 with Bunch(f, 1):
299 pass
300 lock.acquire()
301 lock.release()
302
303 def test_state_after_timeout(self):
304 # Issue #11618: check that lock is in a proper state after a

Callers

nothing calls this directly

Calls 3

BunchClass · 0.70
acquireMethod · 0.45
releaseMethod · 0.45

Tested by

no test coverage detected