forked from VimPlug/jedi-vim
Use python3.6 for tests.
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
sudo: false
|
sudo: false
|
||||||
language: python
|
language: python3.6
|
||||||
env:
|
env:
|
||||||
matrix:
|
matrix:
|
||||||
- ENV=test
|
- ENV=test
|
||||||
@@ -11,7 +11,7 @@ matrix:
|
|||||||
install:
|
install:
|
||||||
- |
|
- |
|
||||||
if [ "$ENV" = "test" ]; then
|
if [ "$ENV" = "test" ]; then
|
||||||
pip install pytest
|
python3.6 -m pip install pytest
|
||||||
fi
|
fi
|
||||||
script:
|
script:
|
||||||
- vim --version
|
- vim --version
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
import urllib
|
import urllib.request
|
||||||
import zipfile
|
import zipfile
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -33,7 +33,7 @@ def pytest_configure(config):
|
|||||||
os.mkdir(CACHE_FOLDER)
|
os.mkdir(CACHE_FOLDER)
|
||||||
|
|
||||||
if not os.path.exists(VSPEC_FOLDER):
|
if not os.path.exists(VSPEC_FOLDER):
|
||||||
name, hdrs = urllib.urlretrieve(VSPEC_URL)
|
name, hdrs = urllib.request.urlretrieve(VSPEC_URL)
|
||||||
z = zipfile.ZipFile(name)
|
z = zipfile.ZipFile(name)
|
||||||
for n in z.namelist():
|
for n in z.namelist():
|
||||||
dest = os.path.join(CACHE_FOLDER, n)
|
dest = os.path.join(CACHE_FOLDER, n)
|
||||||
@@ -42,7 +42,7 @@ def pytest_configure(config):
|
|||||||
os.makedirs(destdir)
|
os.makedirs(destdir)
|
||||||
data = z.read(n)
|
data = z.read(n)
|
||||||
if not os.path.isdir(dest):
|
if not os.path.isdir(dest):
|
||||||
with open(dest, 'w') as f:
|
with open(dest, 'wb') as f:
|
||||||
f.write(data)
|
f.write(data)
|
||||||
z.close()
|
z.close()
|
||||||
os.chmod(VSPEC_RUNNER, 0o777)
|
os.chmod(VSPEC_RUNNER, 0o777)
|
||||||
|
|||||||
Reference in New Issue
Block a user