diff options
author | Jeremy T. Bouse <jbouse@debian.org> | 2014-08-28 22:23:07 -0700 |
---|---|---|
committer | Jeremy T. Bouse <jbouse@debian.org> | 2014-08-28 22:23:07 -0700 |
commit | 588a4823436454e8968ee36ae95ff92e1cddc3f7 (patch) | |
tree | e4a22fe9360117ca8d4d85d9628d7581a57ac97c /tests/test_file.py | |
parent | 4e426087436d01fe00a120e5e7ce7a5e0a1e0970 (diff) | |
download | python-paramiko-588a4823436454e8968ee36ae95ff92e1cddc3f7.tar python-paramiko-588a4823436454e8968ee36ae95ff92e1cddc3f7.tar.gz |
Imported Upstream version 1.14.1upstream/1.14.1
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 c6edd7a..22a34ac 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() |