diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2021-02-06 21:55:29 -0500 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2021-02-06 21:57:26 -0500 |
commit | 2af7e87b26754fea68adfd1b8aa51052d987e60c (patch) | |
tree | 3d81d1e79bebd529240629b9cd43c4f0e273046b /tests/test_concurrency.py | |
parent | e59da1bafafe4265188bb5c75c4e557dfbd47d90 (diff) | |
download | python-coveragepy-git-nedbat/better-combine-action.tar.gz |
refactor: convert all skipping to pytest skipsnedbat/better-combine-action
Diffstat (limited to 'tests/test_concurrency.py')
-rw-r--r-- | tests/test_concurrency.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/tests/test_concurrency.py b/tests/test_concurrency.py index fd7aa851..86c69cf5 100644 --- a/tests/test_concurrency.py +++ b/tests/test_concurrency.py @@ -12,6 +12,7 @@ import threading import time from flaky import flaky +import pytest import coverage from coverage import env @@ -363,15 +364,11 @@ MULTI_CODE = """ """ +@pytest.mark.skipif(not multiprocessing, reason="No multiprocessing in this Python") @flaky(max_runs=30) # Sometimes a test fails due to inherent randomness. Try more times. class MultiprocessingTest(CoverageTest): """Test support of the multiprocessing module.""" - def setUp(self): - if not multiprocessing: - self.skipTest("No multiprocessing in this Python") # pragma: only jython - super(MultiprocessingTest, self).setUp() - def try_multiprocessing_code( self, code, expected_out, the_module, nprocs, concurrency="multiprocessing", args="" ): |