forked from VimPlug/jedi
Remove most version_info.major usages
This commit is contained in:
@@ -9,9 +9,6 @@ def test_simple_annotations(Script, environment):
|
||||
If annotations adhere to PEP-0484, we use them (they override inference),
|
||||
else they are parsed but ignored
|
||||
"""
|
||||
if environment.version_info.major == 2:
|
||||
pytest.skip()
|
||||
|
||||
source = dedent("""\
|
||||
def annot(a:3):
|
||||
return a
|
||||
@@ -45,18 +42,12 @@ def test_simple_annotations(Script, environment):
|
||||
r'1\n'
|
||||
])
|
||||
def test_illegal_forward_references(Script, environment, reference):
|
||||
if environment.version_info.major == 2:
|
||||
pytest.skip()
|
||||
|
||||
source = 'def foo(bar: "%s"): bar' % reference
|
||||
|
||||
assert not Script(source).infer()
|
||||
|
||||
|
||||
def test_lambda_forward_references(Script, environment):
|
||||
if environment.version_info.major == 2:
|
||||
pytest.skip()
|
||||
|
||||
source = 'def foo(bar: "lambda: 3"): bar'
|
||||
|
||||
# For now just receiving the 3 is ok. I'm doubting that this is what we
|
||||
|
||||
Reference in New Issue
Block a user