summaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authorJeff Forcier <jeff@bitprophet.org>2023-04-14 16:45:06 -0400
committerJeff Forcier <jeff@bitprophet.org>2023-05-05 12:27:03 -0400
commit5d3aad0ca44df998bfe37f23d371926ff1a7ffb3 (patch)
treea7df0707d51d971d9a3183bbf2d948a12f80b9db /tests
parent57c33481fda5cd9338df2bb4d5c090f50bcc7343 (diff)
Add algorithm_name property to PKey
Diffstat (limited to 'tests')
-rw-r--r--tests/test_pkey.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_pkey.py b/tests/test_pkey.py
index 477da0e3..b1b9d51c 100644
--- a/tests/test_pkey.py
+++ b/tests/test_pkey.py
@@ -653,6 +653,11 @@ class KeyTest(unittest.TestCase):
"SHA256:J6VESFdD3xSChn8y9PzWzeF+1tl892mOy2TqkMLO4ow",
]
+ def test_algorithm_property(self):
+ # Assumes the RSA, DSS, ECDSA, Ed25519 order seen in 'def keys'.
+ algorithms = [x.algorithm_name for x, _ in self.keys()]
+ assert algorithms == ["RSA", "DSS", "ECDSA", "ED25519"]
+
def test_ed25519_nonbytes_password(self):
# https://github.com/paramiko/paramiko/issues/1039
Ed25519Key.from_private_key_file(