You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 16:59:52 +08:00
Disable hypothesis on 2.6.9
This commit is contained in:
@@ -1,11 +1,15 @@
|
|||||||
# std
|
# std
|
||||||
import os
|
|
||||||
# test
|
# test
|
||||||
|
from uncompyle6 import PYTHON_VERSION, deparse_code
|
||||||
import pytest
|
import pytest
|
||||||
|
pytestmark = pytest.mark.skipif(PYTHON_VERSION <= 2.6,
|
||||||
|
reason='hypothesis needs 2.7 or later')
|
||||||
|
if PYTHON_VERSION > 2.6:
|
||||||
|
|
||||||
import hypothesis
|
import hypothesis
|
||||||
from hypothesis import strategies as st
|
from hypothesis import strategies as st
|
||||||
|
|
||||||
# uncompyle6
|
# uncompyle6
|
||||||
from uncompyle6 import PYTHON_VERSION, deparse_code
|
|
||||||
|
|
||||||
|
|
||||||
@st.composite
|
@st.composite
|
||||||
|
@@ -1,12 +1,13 @@
|
|||||||
# std
|
|
||||||
import string
|
import string
|
||||||
# 3rd party
|
from uncompyle6 import PYTHON_VERSION
|
||||||
from hypothesis import given, assume, example, settings, strategies as st
|
|
||||||
import pytest
|
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 validate import validate_uncompyle
|
||||||
from test_fstring import expressions
|
from test_fstring import expressions
|
||||||
from uncompyle6 import PYTHON_VERSION
|
|
||||||
|
|
||||||
alpha = st.sampled_from(string.ascii_lowercase)
|
alpha = st.sampled_from(string.ascii_lowercase)
|
||||||
numbers = st.sampled_from(string.digits)
|
numbers = st.sampled_from(string.digits)
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||
import pytest
|
import pytest
|
||||||
from uncompyle6 import PYTHON_VERSION, deparse_code
|
from uncompyle6 import PYTHON_VERSION, deparse_code
|
||||||
|
pytestmark = pytest.mark.skip(PYTHON_VERSION < 2.7,
|
||||||
@pytest.mark.skip(PYTHON_VERSION < 2.7,
|
|
||||||
reason="need at least Python 2.7")
|
reason="need at least Python 2.7")
|
||||||
|
|
||||||
|
if PYTHON_VERSION > 2.6:
|
||||||
def test_single_mode():
|
def test_single_mode():
|
||||||
single_expressions = (
|
single_expressions = (
|
||||||
'i = 1',
|
'i = 1',
|
||||||
|
Reference in New Issue
Block a user