aboutsummaryrefslogtreecommitdiffstats
path: root/tests/primitives/test_openssl_vectors.py
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2013-10-06 12:24:47 -0500
committerPaul Kehrer <paul.l.kehrer@gmail.com>2013-10-06 17:31:31 -0500
commit84bb1bb2c04c8e05a072587f9e622f6a5e99de56 (patch)
tree6557c523e04c50733909463235eb977aa2b25ada /tests/primitives/test_openssl_vectors.py
parentf2ce1ae856e43a292ea7a6aae26d75b508f0a363 (diff)
downloadcryptography-84bb1bb2c04c8e05a072587f9e622f6a5e99de56.tar.gz
cryptography-84bb1bb2c04c8e05a072587f9e622f6a5e99de56.tar.bz2
cryptography-84bb1bb2c04c8e05a072587f9e622f6a5e99de56.zip
remove openssl api dependency in test_openssl_vectors
Update some single quotes to double for consistency
Diffstat (limited to 'tests/primitives/test_openssl_vectors.py')
-rw-r--r--tests/primitives/test_openssl_vectors.py19
1 files changed, 9 insertions, 10 deletions
diff --git a/tests/primitives/test_openssl_vectors.py b/tests/primitives/test_openssl_vectors.py
index ccd07194..acb982a5 100644
--- a/tests/primitives/test_openssl_vectors.py
+++ b/tests/primitives/test_openssl_vectors.py
@@ -23,7 +23,6 @@ import os
import pytest
-from cryptography.bindings.openssl.api import api
from cryptography.primitives.block import BlockCipher, ciphers, modes
from ..utils import load_openssl_vectors_from_file
@@ -47,9 +46,9 @@ class TestCamelliaCBC(object):
"camellia-cbc.txt",
]
)
- def test_OpenSSL(self, key, iv, plaintext, ciphertext):
- if not api.supports_cipher('camellia-128-cbc'):
- pytest.skip()
+ def test_OpenSSL(self, key, iv, plaintext, ciphertext, api):
+ if not api.supports_cipher("camellia-128-cbc"):
+ pytest.skip("Does not support Camellia CBC")
cipher = BlockCipher(
ciphers.Camellia(binascii.unhexlify(key)),
modes.CBC(binascii.unhexlify(iv)),
@@ -68,9 +67,9 @@ class TestCamelliaOFB(object):
"camellia-ofb.txt",
]
)
- def test_OpenSSL(self, key, iv, plaintext, ciphertext):
- if not api.supports_cipher('camellia-128-ofb'):
- pytest.skip()
+ def test_OpenSSL(self, key, iv, plaintext, ciphertext, api):
+ if not api.supports_cipher("camellia-128-ofb"):
+ pytest.skip("Does not support Camellia OFB")
cipher = BlockCipher(
ciphers.Camellia(binascii.unhexlify(key)),
modes.OFB(binascii.unhexlify(iv)),
@@ -89,9 +88,9 @@ class TestCamelliaCFB(object):
"camellia-cfb.txt",
]
)
- def test_OpenSSL(self, key, iv, plaintext, ciphertext):
- if not api.supports_cipher('camellia-128-cfb'):
- pytest.skip()
+ def test_OpenSSL(self, key, iv, plaintext, ciphertext, api):
+ if not api.supports_cipher("camellia-128-cfb"):
+ pytest.skip("Does not support Camellia CFB")
cipher = BlockCipher(
ciphers.Camellia(binascii.unhexlify(key)),
modes.CFB(binascii.unhexlify(iv)),