diff options
author | Andrew M. Kuchling <amk@amk.ca> | 2000-07-11 10:45:28 (GMT) |
---|---|---|
committer | Andrew M. Kuchling <amk@amk.ca> | 2000-07-11 10:45:28 (GMT) |
commit | d3cf692c387a49a4a3791a3ee201ff9a61889843 (patch) | |
tree | 319641490f43edceaabcce96053dc738dd8ce480 /Lib | |
parent | e0d0090e76075a983d42aedad1c4fc2e77db847c (diff) | |
download | cpython-d3cf692c387a49a4a3791a3ee201ff9a61889843.zip cpython-d3cf692c387a49a4a3791a3ee201ff9a61889843.tar.gz cpython-d3cf692c387a49a4a3791a3ee201ff9a61889843.tar.bz2 |
Add test of resize() method of mmap objects
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/output/test_mmap | bin | 520 -> 542 bytes | |||
-rw-r--r-- | Lib/test/test_mmap.py | 13 |
2 files changed, 13 insertions, 0 deletions
diff --git a/Lib/test/output/test_mmap b/Lib/test/output/test_mmap Binary files differindex 0e880e3..2ceed20 100644 --- a/Lib/test/output/test_mmap +++ b/Lib/test/output/test_mmap diff --git a/Lib/test/test_mmap.py b/Lib/test/test_mmap.py index c3cafca..171eb14 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' |