1
0
forked from VimPlug/jedi

This test will be removed in the virtualenv branch

This commit is contained in:
Hugo
2018-01-07 10:39:38 +02:00
parent 7e449af4bd
commit 73c71d6475

View File

@@ -45,5 +45,20 @@ def generate_pyc():
shutil.copy(os.path.join("dummy_package/__pycache__", f), dst)
# Python 2.6 does not necessarily come with `compileall.compile_file`.
@pytest.mark.skipif("sys.version_info > (2,6)")
@cwd_at('test/test_evaluate')
def test_pyc():
"""
The list of completion must be greater than 2.
"""
try:
generate_pyc()
s = jedi.Script("from dummy_package import dummy; dummy.", path='blub.py')
assert len(s.completions()) >= 2
finally:
shutil.rmtree("dummy_package")
if __name__ == "__main__":
test_pyc()