summaryrefslogtreecommitdiffstats
path: root/Lib/test/_test_multiprocessing.py
diff options
context:
space:
mode:
authorThomas Moreau <thomas.moreau.2010@gmail.com>2018-03-21 17:56:27 (GMT)
committerAntoine Pitrou <pitrou@free.fr>2018-03-21 17:56:27 (GMT)
commitdec1c7786f642049c2508e909442189dc043b5da (patch)
tree3516146e3c3c9c15b7a16f37614582695976702a /Lib/test/_test_multiprocessing.py
parente2f33add635df4fde81be9960bab367e010c19bf (diff)
downloadcpython-dec1c7786f642049c2508e909442189dc043b5da.zip
cpython-dec1c7786f642049c2508e909442189dc043b5da.tar.gz
cpython-dec1c7786f642049c2508e909442189dc043b5da.tar.bz2
FIX failure on OSX sem_getvalue (#6180)
Diffstat (limited to 'Lib/test/_test_multiprocessing.py')
-rw-r--r--Lib/test/_test_multiprocessing.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/Lib/test/_test_multiprocessing.py b/Lib/test/_test_multiprocessing.py
index c787702..c6a1f5c 100644
--- a/Lib/test/_test_multiprocessing.py
+++ b/Lib/test/_test_multiprocessing.py
@@ -1062,11 +1062,16 @@ class _TestQueue(BaseTestCase):
q = self.Queue(maxsize=1)
q.put(NotSerializable())
q.put(True)
- self.assertEqual(q.qsize(), 1)
+ try:
+ self.assertEqual(q.qsize(), 1)
+ except NotImplementedError:
+ # qsize is not available on all platform as it
+ # relies on sem_getvalue
+ pass
# bpo-30595: use a timeout of 1 second for slow buildbots
self.assertTrue(q.get(timeout=1.0))
# Check that the size of the queue is correct
- self.assertEqual(q.qsize(), 0)
+ self.assertTrue(q.empty())
close_queue(q)
def test_queue_feeder_on_queue_feeder_error(self):