diff options
author | Jeff Forcier <jeff@bitprophet.org> | 2014-09-08 15:59:05 -0700 |
---|---|---|
committer | Jeff Forcier <jeff@bitprophet.org> | 2014-09-08 15:59:05 -0700 |
commit | 752507a2978b0c6091ee737cd37ba1cb690926a2 (patch) | |
tree | 2610670fc4edd07ae96851c4947a3c69d360cb88 /tests/test_file.py | |
parent | b076c10d00ee2cb4d465291a4ef0a4be9f048d9a (diff) | |
parent | de391e88e0a7e75cd977f162a883aa5ffdbdc591 (diff) |
Merge branch 'master' into 267-int
Conflicts:
paramiko/client.py
paramiko/transport.py
sites/www/changelog.rst
Diffstat (limited to 'tests/test_file.py')
-rwxr-xr-x | tests/test_file.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_file.py b/tests/test_file.py index c6edd7af..22a34aca 100755 --- a/tests/test_file.py +++ b/tests/test_file.py @@ -23,6 +23,7 @@ Some unit tests for the BufferedFile abstraction. import unittest from paramiko.file import BufferedFile from paramiko.common import linefeed_byte, crlf, cr_byte +import sys class LoopbackFile (BufferedFile): @@ -151,6 +152,15 @@ class BufferedFileTest (unittest.TestCase): b'need to close them again.\n') f.close() + def test_8_buffering(self): + """ + verify that buffered objects can be written + """ + if sys.version_info[0] == 2: + f = LoopbackFile('r+', 16) + f.write(buffer(b'Too small.')) + f.close() + if __name__ == '__main__': from unittest import main main() |