mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
[3.11] Reorder some test's decorators (GH-108804) (GH-108845)
For example, do not demand the 'cpu' resource if the test cannot be run
due to non-working threads.
(cherry picked from commit 509bb61977
)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
This commit is contained in:
parent
b30c83eb21
commit
ba47d87282
2 changed files with 4 additions and 4 deletions
|
@ -1459,8 +1459,8 @@ class BufferedReaderTest(unittest.TestCase, CommonBufferedTests):
|
|||
|
||||
self.assertEqual(b"abcdefg", bufio.read())
|
||||
|
||||
@support.requires_resource('cpu')
|
||||
@threading_helper.requires_working_threading()
|
||||
@support.requires_resource('cpu')
|
||||
def test_threads(self):
|
||||
try:
|
||||
# Write out many bytes with exactly the same number of 0's,
|
||||
|
@ -1834,8 +1834,8 @@ class BufferedWriterTest(unittest.TestCase, CommonBufferedTests):
|
|||
f.truncate()
|
||||
self.assertEqual(f.tell(), buffer_size + 2)
|
||||
|
||||
@support.requires_resource('cpu')
|
||||
@threading_helper.requires_working_threading()
|
||||
@support.requires_resource('cpu')
|
||||
def test_threads(self):
|
||||
try:
|
||||
# Write out many bytes from many threads and test they were
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue