summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Coghlan <ncoghlan@gmail.com>2013-12-19 11:53:31 (GMT)
committerNick Coghlan <ncoghlan@gmail.com>2013-12-19 11:53:31 (GMT)
commitfeae73e13fb15b06a5f798ed153ed534077f0465 (patch)
tree3e6270d4005a61ff1ae3e4259c30ef4a3b066a35
parentf468d5b259ed4c1a33a84d4867de05596d44a292 (diff)
downloadcpython-feae73e13fb15b06a5f798ed153ed534077f0465.zip
cpython-feae73e13fb15b06a5f798ed153ed534077f0465.tar.gz
cpython-feae73e13fb15b06a5f798ed153ed534077f0465.tar.bz2
Issue #19946: appropriately skip new multiprocessing tests
Thanks to Christian Heimes for noting the buildbot failures and to Zachary Ware for providing the patch to make the new tests play nice with both other platforms and unittest test discovery
-rw-r--r--Lib/test/test_multiprocessing_main_handling.py14
1 files changed, 5 insertions, 9 deletions
diff --git a/Lib/test/test_multiprocessing_main_handling.py b/Lib/test/test_multiprocessing_main_handling.py
index 007fc54..7c201a3 100644
--- a/Lib/test/test_multiprocessing_main_handling.py
+++ b/Lib/test/test_multiprocessing_main_handling.py
@@ -130,10 +130,9 @@ def _make_launch_script(script_dir, script_basename, module_name, path=None):
class MultiProcessingCmdLineMixin():
maxDiff = None # Show full tracebacks on subprocess failure
- def setupClass(cls):
- if cls.start_method not in _concrete_contexts:
- raise unittest.SkipTest("%r start method not available" %
- cls.start_method)
+ def setUp(self):
+ if self.start_method not in _concrete_contexts:
+ self.skipTest("%r start method not available" % self.start_method)
def _check_output(self, script_name, exit_code, out, err):
if verbose > 1:
@@ -277,11 +276,8 @@ class ForkServerCmdLineTest(MultiProcessingCmdLineMixin, unittest.TestCase):
start_method = 'forkserver'
main_in_children_source = test_source_main_skipped_in_children
-def test_main():
- support.run_unittest(SpawnCmdLineTest,
- ForkCmdLineTest,
- ForkServerCmdLineTest)
+def tearDownModule():
support.reap_children()
if __name__ == '__main__':
- test_main()
+ unittest.main()