From: Andrew M. Kuchling Date: Tue, 11 Jul 2000 10:45:28 +0000 (+0000) Subject: Add test of resize() method of mmap objects X-Git-Tag: v2.0b1~900 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d3cf692c387a49a4a3791a3ee201ff9a61889843;p=thirdparty%2FPython%2Fcpython.git Add test of resize() method of mmap objects --- diff --git a/Lib/test/output/test_mmap b/Lib/test/output/test_mmap index 0e880e38cdf2..2ceed20e3104 100644 Binary files a/Lib/test/output/test_mmap and b/Lib/test/output/test_mmap differ diff --git a/Lib/test/test_mmap.py b/Lib/test/test_mmap.py index c3cafca8341a..171eb1497c04 100644 --- a/Lib/test/test_mmap.py +++ b/Lib/test/test_mmap.py @@ -94,6 +94,19 @@ def test_both(): else: assert 0, 'expected a ValueError but did not get it' + # Try resizing map + print ' Attempting resize()' + try: + m.resize( 512 ) + except SystemError: + # resize() not supported + # No messages are printed, since the output of this test suite + # would then be different across platforms. + pass + else: + # resize() is supported + pass + m.close() os.unlink("foo") print ' Test passed'