diff options
-rw-r--r-- | paramiko/_winapi.py | 5 | ||||
-rw-r--r-- | paramiko/hostkeys.py | 5 | ||||
-rw-r--r-- | tests/test_file.py | 9 |
3 files changed, 2 insertions, 17 deletions
diff --git a/paramiko/_winapi.py b/paramiko/_winapi.py index 4cb5dff9..fcc18552 100644 --- a/paramiko/_winapi.py +++ b/paramiko/_winapi.py @@ -61,10 +61,7 @@ class WindowsError(builtins.WindowsError): if value is None: value = ctypes.windll.kernel32.GetLastError() strerror = format_system_message(value) - if sys.version_info > (3, 3): - args = 0, strerror, None, value - else: - args = value, strerror + args = 0, strerror, None, value super(WindowsError, self).__init__(*args) @property diff --git a/paramiko/hostkeys.py b/paramiko/hostkeys.py index 5ff15416..dc8fb8d0 100644 --- a/paramiko/hostkeys.py +++ b/paramiko/hostkeys.py @@ -22,10 +22,7 @@ import binascii import os import sys -if sys.version_info[:2] >= (3, 3): - from collections.abc import MutableMapping -else: - from collections import MutableMapping +from collections.abc import MutableMapping from hashlib import sha1 from hmac import HMAC diff --git a/tests/test_file.py b/tests/test_file.py index cbee62ef..b0147450 100644 --- a/tests/test_file.py +++ b/tests/test_file.py @@ -162,15 +162,6 @@ class BufferedFileTest(unittest.TestCase): ) f.close() - def test_buffering_writes(self): - """ - verify that buffered objects can be written - """ - if sys.version_info[0] == 2: - f = LoopbackFile("r+", 16) - f.write(buffer(b"Too small.")) # noqa - f.close() - def test_readable(self): f = LoopbackFile("r") self.assertTrue(f.readable()) |