From e06cc67c1938fa4786aa3f5cd8bb2e7fd65754cf Mon Sep 17 00:00:00 2001 From: Benjamin Peterson Date: Wed, 5 Oct 2016 22:00:05 -0700 Subject: skip test if resizing is not supported --- Lib/test/test_mmap.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Lib/test/test_mmap.py b/Lib/test/test_mmap.py index f8de8c2..b8a0135 100644 --- a/Lib/test/test_mmap.py +++ b/Lib/test/test_mmap.py @@ -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) -- cgit v0.12