aboutsummaryrefslogtreecommitdiffstats
path: root/tests/hazmat/primitives/test_arc4.py
diff options
context:
space:
mode:
authorAlex Gaynor <alex.gaynor@gmail.com>2013-12-27 16:16:41 -0800
committerAlex Gaynor <alex.gaynor@gmail.com>2013-12-27 16:16:41 -0800
commit7ede6a4b80677bf56088b8492fa87b19183db448 (patch)
treea779758c943ba22310b8ba3bd7b3202446417503 /tests/hazmat/primitives/test_arc4.py
parent9b51cc1a843d6a8427eb4ad49aeaf5317c442fed (diff)
parentb078d8e1f446a1d2d13453e65e37fbaf4f6b17f2 (diff)
downloadcryptography-7ede6a4b80677bf56088b8492fa87b19183db448.tar.gz
cryptography-7ede6a4b80677bf56088b8492fa87b19183db448.tar.bz2
cryptography-7ede6a4b80677bf56088b8492fa87b19183db448.zip
Merge pull request #353 from reaperhulk/supported-mark
Add mark that allows us to do skip tests on backends via decorators
Diffstat (limited to 'tests/hazmat/primitives/test_arc4.py')
-rw-r--r--tests/hazmat/primitives/test_arc4.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/hazmat/primitives/test_arc4.py b/tests/hazmat/primitives/test_arc4.py
index f2e2452c..33f7ff09 100644
--- a/tests/hazmat/primitives/test_arc4.py
+++ b/tests/hazmat/primitives/test_arc4.py
@@ -24,6 +24,12 @@ from .utils import generate_stream_encryption_test
from ...utils import load_nist_vectors
+@pytest.mark.supported(
+ only_if=lambda backend: backend.cipher_supported(
+ algorithms.ARC4("\x00" * 16), None
+ ),
+ skip_message="Does not support ARC4",
+)
@pytest.mark.cipher
class TestARC4(object):
test_rfc = generate_stream_encryption_test(
@@ -39,8 +45,4 @@ class TestARC4(object):
"rfc-6229-256.txt",
],
lambda key, **kwargs: algorithms.ARC4(binascii.unhexlify(key)),
- only_if=lambda backend: backend.cipher_supported(
- algorithms.ARC4("\x00" * 16), None
- ),
- skip_message="Does not support ARC4",
)