diff options
author | Alex Gaynor <alex.gaynor@gmail.com> | 2013-10-16 14:17:36 -0700 |
---|---|---|
committer | Alex Gaynor <alex.gaynor@gmail.com> | 2013-10-16 14:17:36 -0700 |
commit | a20631d332d47903a85b61c4b68c5398125a3ebe (patch) | |
tree | 82d10997cba9841c05feb386a32d826de48fba32 | |
parent | 016eed1cc1cc26ff404ac31ed3858de362ca37f2 (diff) | |
download | cryptography-a20631d332d47903a85b61c4b68c5398125a3ebe.tar.gz cryptography-a20631d332d47903a85b61c4b68c5398125a3ebe.tar.bz2 cryptography-a20631d332d47903a85b61c4b68c5398125a3ebe.zip |
Consolidate this list
-rw-r--r-- | cryptography/bindings/__init__.py | 7 | ||||
-rw-r--r-- | tests/conftest.py | 4 | ||||
-rw-r--r-- | tests/primitives/utils.py | 4 |
3 files changed, 9 insertions, 6 deletions
diff --git a/cryptography/bindings/__init__.py b/cryptography/bindings/__init__.py index 8b165009..215f17c7 100644 --- a/cryptography/bindings/__init__.py +++ b/cryptography/bindings/__init__.py @@ -11,7 +11,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -from cryptography.bindings.openssl import api +from cryptography.bindings import openssl -_default_api = api +_default_api = openssl.api +_ALL_APIS = [ + openssl.api +] diff --git a/tests/conftest.py b/tests/conftest.py index d16be3b6..b526f2bf 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,5 +1,5 @@ def pytest_generate_tests(metafunc): - from cryptography.bindings.openssl import api + from cryptography.bindings import _ALL_APIS if "api" in metafunc.fixturenames: - metafunc.parametrize("api", [api]) + metafunc.parametrize("api", _ALL_APIS) diff --git a/tests/primitives/utils.py b/tests/primitives/utils.py index 13bf0d89..addd7123 100644 --- a/tests/primitives/utils.py +++ b/tests/primitives/utils.py @@ -3,14 +3,14 @@ import os import pytest -from cryptography.bindings import openssl +from cryptography.bindings import _ALL_APIS from cryptography.primitives.block import BlockCipher def generate_encrypt_test(param_loader, path, file_names, cipher_factory, mode_factory, only_if=lambda api: True): def test_encryption(self): - for api in [openssl.api]: + for api in _ALL_APIS: if not only_if(api): yield encrypt_skipped else: |