aboutsummaryrefslogtreecommitdiffstats
path: root/tests/hazmat/backends/test_openssl.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/hazmat/backends/test_openssl.py')
-rw-r--r--tests/hazmat/backends/test_openssl.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/tests/hazmat/backends/test_openssl.py b/tests/hazmat/backends/test_openssl.py
index 35b7c5c3..b5de702d 100644
--- a/tests/hazmat/backends/test_openssl.py
+++ b/tests/hazmat/backends/test_openssl.py
@@ -503,18 +503,16 @@ class TestRSAPEMSerialization(object):
key = RSA_KEY_2048.private_key(backend)
with pytest.raises(ValueError):
key.dump(
- serialization.PKCS8(
- serialization.Encoding.PEM
- ),
- serialization.BestAvailable(password)
+ serialization.Encoding.PEM,
+ serialization.Format.PKCS8,
+ serialization.BestAvailableEncryption(password)
)
def test_unsupported_key_encoding(self):
key = RSA_KEY_2048.private_key(backend)
with pytest.raises(ValueError):
key.dump(
- serialization.PKCS8(
- serialization.Encoding.DER
- ),
+ serialization.Encoding.DER,
+ serialization.Format.PKCS8,
serialization.NoEncryption()
)