Skip to content
Snippets Groups Projects
Commit 64a4099a authored by Ian Cordasco's avatar Ian Cordasco Committed by GitHub
Browse files

Merge pull request #45 from asottile/py36

Test against python3.6
parents 1a754b92 512369c6
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -19,6 +19,8 @@ matrix:
env: TOXENV=py34
- python: 3.5
env: TOXENV=py35
- python: 3.6
env: TOXENV=py36
- python: pypy
env: TOXENV=pypy
- env: TOXENV=docstrings
Loading
Loading
Loading
Loading
@@ -53,6 +53,7 @@ setup(
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Topic :: Software Development :: Libraries :: Python Modules',
'Topic :: Software Development :: Quality Assurance',
],
Loading
Loading
Loading
Loading
@@ -105,6 +105,11 @@ async def foobar(a, b, c):
pass
"""
 
annotated_assign = """\
def f():
x: Any = None
"""
 
def get_complexity_number(snippet, strio, max=0):
"""Get the complexity number from the printed string."""
Loading
Loading
@@ -196,6 +201,14 @@ class McCabeTestCase(unittest.TestCase):
complexity = get_complexity_number(async_keywords, self.strio)
self.assertEqual(complexity, 3)
 
@pytest.mark.skipif(
sys.version_info < (3, 6),
reason="Annotated assignments are only valid on Python 3.6+",
)
def test_annotated_assignment(self):
complexity = get_complexity_number(annotated_assign, self.strio)
self.assertEqual(complexity, 1)
 
class RegressionTests(unittest.TestCase):
def setUp(self):
Loading
Loading
[tox]
envlist =
py26,py27,py33,py34,py35,flake8
py26,py27,py33,py34,py35,py36,flake8
 
[testenv]
deps =
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment