summaryrefslogtreecommitdiff
path: root/Lib/test/test_multiprocessing.py
diff options
context:
space:
mode:
authorZachary Ware <zachary.ware@gmail.com>2013-12-08 00:20:35 -0600
committerZachary Ware <zachary.ware@gmail.com>2013-12-08 00:20:35 -0600
commit9fe6d86709b0e769602ff55a6e5a202c440b9d8a (patch)
treeec3d7b1b0cbbd15658459e397c6905964c192331 /Lib/test/test_multiprocessing.py
parent774f909489ca1395ba1e3f3a1f3d43495df6cdfe (diff)
downloadcpython-git-9fe6d86709b0e769602ff55a6e5a202c440b9d8a.tar.gz
Issue 19572: More silently skipped tests explicitly skipped.
Diffstat (limited to 'Lib/test/test_multiprocessing.py')
-rw-r--r--Lib/test/test_multiprocessing.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/Lib/test/test_multiprocessing.py b/Lib/test/test_multiprocessing.py
index 27db029b3c..d20a57698d 100644
--- a/Lib/test/test_multiprocessing.py
+++ b/Lib/test/test_multiprocessing.py
@@ -195,7 +195,7 @@ class _TestProcess(BaseTestCase):
def test_current(self):
if self.TYPE == 'threads':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
current = self.current_process()
authkey = current.authkey
@@ -209,7 +209,7 @@ class _TestProcess(BaseTestCase):
def test_daemon_argument(self):
if self.TYPE == "threads":
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
# By default uses the current process's daemon flag.
proc0 = self.Process(target=self._test)
@@ -274,7 +274,7 @@ class _TestProcess(BaseTestCase):
def test_terminate(self):
if self.TYPE == 'threads':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
p = self.Process(target=self._test_terminate)
p.daemon = True
@@ -378,7 +378,7 @@ class _TestProcess(BaseTestCase):
def test_sentinel(self):
if self.TYPE == "threads":
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
event = self.Event()
p = self.Process(target=self._test_sentinel, args=(event,))
with self.assertRaises(ValueError):
@@ -434,7 +434,7 @@ class _TestSubclassingProcess(BaseTestCase):
def test_stderr_flush(self):
# sys.stderr is flushed at process shutdown (issue #13812)
if self.TYPE == "threads":
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
testfn = test.support.TESTFN
self.addCleanup(test.support.unlink, testfn)
@@ -462,7 +462,7 @@ class _TestSubclassingProcess(BaseTestCase):
def test_sys_exit(self):
# See Issue 13854
if self.TYPE == 'threads':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
testfn = test.support.TESTFN
self.addCleanup(test.support.unlink, testfn)
@@ -671,7 +671,7 @@ class _TestQueue(BaseTestCase):
try:
self.assertEqual(q.qsize(), 0)
except NotImplementedError:
- return
+ self.skipTest('qsize method not implemented')
q.put(1)
self.assertEqual(q.qsize(), 1)
q.put(5)
@@ -779,7 +779,7 @@ class _TestSemaphore(BaseTestCase):
def test_timeout(self):
if self.TYPE != 'processes':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
sem = self.Semaphore(0)
acquire = TimingWrapper(sem.acquire)
@@ -1399,7 +1399,7 @@ class _TestBarrier(BaseTestCase):
def test_thousand(self):
if self.TYPE == 'manager':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
passes = 1000
lock = self.Lock()
conn, child_conn = self.Pipe(False)
@@ -1694,7 +1694,7 @@ class _TestPool(BaseTestCase):
def test_map_unplicklable(self):
# Issue #19425 -- failure to pickle should not cause a hang
if self.TYPE == 'threads':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
class A(object):
def __reduce__(self):
raise RuntimeError('cannot pickle')
@@ -2188,7 +2188,7 @@ class _TestConnection(BaseTestCase):
def test_sendbytes(self):
if self.TYPE != 'processes':
- return
+ self.skipTest('test not appropriate for {}'.format(self.TYPE))
msg = latin('abcdefghijklmnopqrstuvwxyz')
a, b = self.Pipe()