From: Benjamin Peterson Date: Thu, 6 Oct 2016 05:00:05 +0000 (-0700) Subject: skip test if resizing is not supported X-Git-Tag: v3.6.0b2~42^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e06cc67c1938fa4786aa3f5cd8bb2e7fd65754cf;p=python skip test if resizing is not supported --- diff --git a/Lib/test/test_mmap.py b/Lib/test/test_mmap.py index f8de8c2e63..b8a0135043 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)