mirror of
https://github.com/python/cpython.git
synced 2025-10-17 04:08:28 +00:00
bpo-40280: Detect missing threading on WASM platforms (GH-32352)
Co-authored-by: Brett Cannon <brett@python.org>
This commit is contained in:
parent
5aee46b31b
commit
2b16a08bc7
33 changed files with 103 additions and 21 deletions
|
@ -87,6 +87,7 @@ class BlockingTestMixin:
|
|||
self.fail("trigger thread ended but event never set")
|
||||
|
||||
|
||||
@threading_helper.requires_working_threading()
|
||||
class BaseQueueTestMixin(BlockingTestMixin):
|
||||
def setUp(self):
|
||||
self.cum = 0
|
||||
|
@ -289,6 +290,8 @@ class CPriorityQueueTest(PriorityQueueTest, unittest.TestCase):
|
|||
# A Queue subclass that can provoke failure at a moment's notice :)
|
||||
class FailingQueueException(Exception): pass
|
||||
|
||||
|
||||
@threading_helper.requires_working_threading()
|
||||
class FailingQueueTest(BlockingTestMixin):
|
||||
|
||||
def setUp(self):
|
||||
|
@ -464,6 +467,7 @@ class BaseSimpleQueueTest:
|
|||
return
|
||||
results.append(val)
|
||||
|
||||
@threading_helper.requires_working_threading()
|
||||
def run_threads(self, n_threads, q, inputs, feed_func, consume_func):
|
||||
results = []
|
||||
sentinel = None
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue