mirror of
https://github.com/python/cpython.git
synced 2025-12-15 21:44:50 +00:00
skip test if resizing is not supported
This commit is contained in:
parent
cd04db03de
commit
e06cc67c19
1 changed files with 4 additions and 1 deletions
|
|
@ -717,7 +717,10 @@ class MmapTests(unittest.TestCase):
|
|||
m = mmap.mmap(-1, 8192)
|
||||
self.addCleanup(m.close)
|
||||
m.read(5000)
|
||||
m.resize(4096)
|
||||
try:
|
||||
m.resize(4096)
|
||||
except SystemError:
|
||||
self.skipTest("resizing not supported")
|
||||
self.assertEqual(m.read(14), b'')
|
||||
self.assertRaises(ValueError, m.read_byte,)
|
||||
self.assertRaises(ValueError, m.write_byte, 42)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue