diff options
author | Alex Gaynor <alex.gaynor@gmail.com> | 2014-06-06 21:58:02 -0700 |
---|---|---|
committer | Alex Gaynor <alex.gaynor@gmail.com> | 2014-06-06 21:58:02 -0700 |
commit | 48b3cb91810445401688596e816032ba6198b549 (patch) | |
tree | 7580b4366fd5218fbea286600f1a0cf6f7a197a5 /tests/hazmat/primitives | |
parent | 0797b1ff7a5cc6d37d85919e47f78412529efb43 (diff) | |
download | cryptography-48b3cb91810445401688596e816032ba6198b549.tar.gz cryptography-48b3cb91810445401688596e816032ba6198b549.tar.bz2 cryptography-48b3cb91810445401688596e816032ba6198b549.zip |
Fixed serialization tests
Diffstat (limited to 'tests/hazmat/primitives')
-rw-r--r-- | tests/hazmat/primitives/test_serialization.py | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/tests/hazmat/primitives/test_serialization.py b/tests/hazmat/primitives/test_serialization.py index 53a5806f..4aa9707f 100644 --- a/tests/hazmat/primitives/test_serialization.py +++ b/tests/hazmat/primitives/test_serialization.py @@ -552,25 +552,11 @@ class TestPKCS8Serialisation(object): @pytest.mark.rsa class TestLoadRSANumbers(object): def test_load_private_numbers(self, backend): - numbers = rsa.RSAPrivateNumbers( - p=RSA_KEY_1024["p"], - q=RSA_KEY_1024["q"], - d=RSA_KEY_1024["private_exponent"], - dmp1=RSA_KEY_1024["dmp1"], - dmq1=RSA_KEY_1024["dmq1"], - iqmp=RSA_KEY_1024["iqmp"], - public_numbers=rsa.RSAPublicNumbers( - n=RSA_KEY_1024["modulus"], - e=RSA_KEY_1024["public_exponent"] - ) - ) - private_key = load_rsa_private_numbers(numbers, backend) + private_key = load_rsa_private_numbers(RSA_KEY_1024, backend) assert private_key def test_load_public_numbers(self, backend): - numbers = rsa.RSAPublicNumbers( - n=RSA_KEY_1024["modulus"], - e=RSA_KEY_1024["public_exponent"] + public_key = load_rsa_public_numbers( + RSA_KEY_1024.public_numbers, backend ) - public_key = load_rsa_public_numbers(numbers, backend) assert public_key |