summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_queue.py
diff options
context:
space:
mode:
authorChristian Heimes <christian@python.org>2022-04-07 07:22:47 (GMT)
committerGitHub <noreply@github.com>2022-04-07 07:22:47 (GMT)
commit2b16a08bc77475917dd5c96417aef4c5210b45ac (patch)
tree6188ad8008760a8710ba6692c44c25157c69d981 /Lib/test/test_queue.py
parent5aee46b31ba37d65cdf4d5a96cabb8835c508deb (diff)
downloadcpython-2b16a08bc77475917dd5c96417aef4c5210b45ac.zip
cpython-2b16a08bc77475917dd5c96417aef4c5210b45ac.tar.gz
cpython-2b16a08bc77475917dd5c96417aef4c5210b45ac.tar.bz2
bpo-40280: Detect missing threading on WASM platforms (GH-32352)
Co-authored-by: Brett Cannon <brett@python.org>
Diffstat (limited to 'Lib/test/test_queue.py')
-rw-r--r--Lib/test/test_queue.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/test_queue.py b/Lib/test/test_queue.py
index cfa6003..e308037 100644
--- a/Lib/test/test_queue.py
+++ b/Lib/test/test_queue.py
@@ -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