Disable hypothesis on 2.6.9

This commit is contained in:
rocky
2018-06-12 14:34:54 -04:00
parent 3b8e6635e2
commit ac2bbfc65a
3 changed files with 292 additions and 286 deletions

View File

@@ -1,11 +1,15 @@
# std
import os
# test
from uncompyle6 import PYTHON_VERSION, deparse_code
import pytest
pytestmark = pytest.mark.skipif(PYTHON_VERSION <= 2.6,
reason='hypothesis needs 2.7 or later')
if PYTHON_VERSION > 2.6:
import hypothesis
from hypothesis import strategies as st
# uncompyle6
from uncompyle6 import PYTHON_VERSION, deparse_code
@st.composite

View File

@@ -1,12 +1,13 @@
# std
import string
# 3rd party
from hypothesis import given, assume, example, settings, strategies as st
from uncompyle6 import PYTHON_VERSION
import pytest
# uncompyle
pytestmark = pytest.mark.skip(PYTHON_VERSION < 2.7,
reason="need at least Python 2.7")
if PYTHON_VERSION > 2.6:
from hypothesis import given, assume, example, settings, strategies as st
from validate import validate_uncompyle
from test_fstring import expressions
from uncompyle6 import PYTHON_VERSION
alpha = st.sampled_from(string.ascii_lowercase)
numbers = st.sampled_from(string.digits)

View File

@@ -1,8 +1,9 @@
import pytest
from uncompyle6 import PYTHON_VERSION, deparse_code
@pytest.mark.skip(PYTHON_VERSION < 2.7,
pytestmark = pytest.mark.skip(PYTHON_VERSION < 2.7,
reason="need at least Python 2.7")
if PYTHON_VERSION > 2.6:
def test_single_mode():
single_expressions = (
'i = 1',