mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-08 23:04:48 +08:00
Add JEDI_TEST_ENVIRONMENT_EXECUTABLE for AppVeyor
This commit is contained in:
@@ -24,10 +24,23 @@ def test_find_python_environments():
|
||||
assert parser_version[:2] == env.version_info[:2]
|
||||
|
||||
|
||||
def test_version():
|
||||
env = Environment('some path', sys.executable)
|
||||
@pytest.mark.skipif("os.name == 'nt'")
|
||||
@pytest.mark.parametrize(
|
||||
'version',
|
||||
['2.7', '3.3', '3.4', '3.5', '3.6', '3.7']
|
||||
)
|
||||
def test_versions(version):
|
||||
executable = 'python' + version
|
||||
try:
|
||||
env = Environment('some path', executable)
|
||||
except InvalidPythonEnvironment:
|
||||
if int(version.replace('.', '')) == py_version:
|
||||
# At least the current version has to work
|
||||
raise
|
||||
return
|
||||
|
||||
sys_path = env.get_sys_path()
|
||||
assert any(sys.prefix in p for p in sys_path)
|
||||
assert any(executable in p for p in sys_path)
|
||||
|
||||
|
||||
def test_load_module(evaluator):
|
||||
|
||||
Reference in New Issue
Block a user