Skip to content

Commit

Permalink
Skip hypothesis tests on Python 2.6.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ayrx committed Mar 22, 2015
1 parent c7ef488 commit 266ed9b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/test_with_hypothesis.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
from hypothesis import given
import pytest

from aead import AEAD


@given(bytes, bytes)
hypothesis = pytest.importorskip("hypothesis")


@hypothesis.given(bytes, bytes)
def test_round_trip_encrypt_decrypt(plaintext, associated_data):
cryptor = AEAD(AEAD.generate_key())
ct = cryptor.encrypt(plaintext, associated_data)
Expand Down
7 changes: 7 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@ commands =
coverage run --source=aead -m pytest --capture=no --strict {posargs}
coverage report -m

[testenv:py26]
deps =
coverage
pytest
commands =
coverage run --source=aead -m pytest --capture=no --strict {posargs}
coverage report -m

[testenv:pep8]
deps =
Expand Down

0 comments on commit 266ed9b

Please sign in to comment.