diff options
author | Jeff Forcier <jeff@bitprophet.org> | 2023-04-14 16:45:06 -0400 |
---|---|---|
committer | Jeff Forcier <jeff@bitprophet.org> | 2023-05-05 12:27:03 -0400 |
commit | 5d3aad0ca44df998bfe37f23d371926ff1a7ffb3 (patch) | |
tree | a7df0707d51d971d9a3183bbf2d948a12f80b9db /tests | |
parent | 57c33481fda5cd9338df2bb4d5c090f50bcc7343 (diff) |
Add algorithm_name property to PKey
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_pkey.py | 5 |
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( |