Refactor tox and ci scripts
Make sure a plain "tox" command works in all platforms without failures, which facilitates making releases using a "devpi upload/test" workflow * Fix small flakes failures * Limit py35 testing to pytest>=2.7, as pytest<2.7 does not work on py35 * pexpect environments only work on Linux platforms and should be skipped on Windows * Simplify AppVeyor script by running all tox environments: no need to have a build matrix because AppVeyor does not execute builds in parallel * Add all environments to travis.yml, obtained from "tox --listenvs"
This commit is contained in:
23
.travis.yml
23
.travis.yml
@@ -7,31 +7,28 @@ install: "pip install -U tox setuptools_scm"
|
|||||||
# # command to run tests
|
# # command to run tests
|
||||||
env:
|
env:
|
||||||
matrix:
|
matrix:
|
||||||
- TESTENV=flakes
|
# note: please use "tox --listenvs" to populate the build matrix
|
||||||
- TESTENV=readme
|
- TESTENV=py26-pytest24
|
||||||
# matrix was trimmed to skip
|
- TESTENV=py26-pytest25
|
||||||
# some builds that are unnecessary/perceived redundant:
|
- TESTENV=py26-pytest26
|
||||||
# py27 and py35 are tested with all pytest versions we declare to support;
|
|
||||||
# py26 and py34 only with latest pytest versions.
|
|
||||||
# pytest24,25,26 don't work on py35 due to changes in ast module
|
|
||||||
- TESTENV=py26-pytest27
|
- TESTENV=py26-pytest27
|
||||||
- TESTENV=py26-pytest28
|
- TESTENV=py26-pytest28
|
||||||
|
|
||||||
- TESTENV=py27-pytest24
|
- TESTENV=py27-pytest24
|
||||||
- TESTENV=py27-pytest25
|
- TESTENV=py27-pytest25
|
||||||
- TESTENV=py27-pytest26
|
- TESTENV=py27-pytest26
|
||||||
- TESTENV=py27-pytest27
|
- TESTENV=py27-pytest27
|
||||||
- TESTENV=py27-pytest28
|
- TESTENV=py27-pytest28
|
||||||
|
- TESTENV=py34-pytest24
|
||||||
|
- TESTENV=py34-pytest25
|
||||||
|
- TESTENV=py34-pytest26
|
||||||
- TESTENV=py34-pytest27
|
- TESTENV=py34-pytest27
|
||||||
- TESTENV=py34-pytest28
|
- TESTENV=py34-pytest28
|
||||||
|
|
||||||
- TESTENV=py35-pytest27
|
- TESTENV=py35-pytest27
|
||||||
- TESTENV=py35-pytest28
|
- TESTENV=py35-pytest28
|
||||||
|
|
||||||
- TESTENV=py27-pytest28-pexpect
|
- TESTENV=py27-pytest28-pexpect
|
||||||
- TESTENV=py34-pytest28-pexpect
|
- TESTENV=py35-pytest28-pexpect
|
||||||
- TESTENV=pypy-pytest28
|
- TESTENV=flakes
|
||||||
|
- TESTENV=readme
|
||||||
|
|
||||||
script: tox --recreate -e $TESTENV
|
script: tox --recreate -e $TESTENV
|
||||||
|
|
||||||
|
|||||||
14
appveyor.yml
14
appveyor.yml
@@ -1,17 +1,7 @@
|
|||||||
environment:
|
|
||||||
matrix:
|
|
||||||
- PYTHON: "C:\\Python35"
|
|
||||||
TESTENV: "py35"
|
|
||||||
|
|
||||||
- PYTHON: "C:\\Python27"
|
|
||||||
TESTENV: "py27"
|
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
|
- C:\Python35\python -m pip install tox setuptools_scm
|
||||||
- pip install tox setuptools_scm"
|
|
||||||
|
|
||||||
build: false # Not a C# project, build stuff at the test step instead.
|
build: false # Not a C# project, build stuff at the test step instead.
|
||||||
|
|
||||||
test_script:
|
test_script:
|
||||||
# Build the compiled extension and run the project tests
|
- C:\Python35\python -m tox
|
||||||
- tox -e %TESTENV%-pytest27,%TESTENV%-pytest28,readme,flakes
|
|
||||||
|
|||||||
@@ -2,9 +2,10 @@ import py
|
|||||||
from xdist.slavemanage import SlaveController, unserialize_report
|
from xdist.slavemanage import SlaveController, unserialize_report
|
||||||
from xdist.remote import serialize_report
|
from xdist.remote import serialize_report
|
||||||
import execnet
|
import execnet
|
||||||
queue = py.builtin._tryimport("queue", "Queue")
|
|
||||||
import marshal
|
import marshal
|
||||||
|
|
||||||
|
queue = py.builtin._tryimport("queue", "Queue")
|
||||||
|
|
||||||
WAIT_TIMEOUT = 10.0
|
WAIT_TIMEOUT = 10.0
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
9
tox.ini
9
tox.ini
@@ -1,6 +1,11 @@
|
|||||||
[tox]
|
[tox]
|
||||||
|
# if you change the envlist, please update .travis.yml file as well
|
||||||
envlist=
|
envlist=
|
||||||
py{26,27,34,35}-pytest2{4,5,6,7,8},py{27,34}-pytest28-pexpect,flakes,readme
|
py{26,27,34}-pytest2{4,5,6,7,8}
|
||||||
|
py35-pytest2{7,8}
|
||||||
|
py{27,35}-pytest28-pexpect
|
||||||
|
flakes
|
||||||
|
readme
|
||||||
|
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
@@ -15,6 +20,8 @@ deps =
|
|||||||
pytest27: pytest~=2.7.2
|
pytest27: pytest~=2.7.2
|
||||||
pytest28: pytest~=2.8.3
|
pytest28: pytest~=2.8.3
|
||||||
pexpect: pexpect
|
pexpect: pexpect
|
||||||
|
platform=
|
||||||
|
pexpect: linux|darwin
|
||||||
commands=
|
commands=
|
||||||
# always clean to avoid code unmarshal mismatch on old python/pytest
|
# always clean to avoid code unmarshal mismatch on old python/pytest
|
||||||
py.cleanup -aq
|
py.cleanup -aq
|
||||||
|
|||||||
@@ -1,2 +1,3 @@
|
|||||||
__all__ = ['__version__']
|
|
||||||
from xdist._version import version as __version__
|
from xdist._version import version as __version__
|
||||||
|
|
||||||
|
__all__ = ['__version__']
|
||||||
|
|||||||
Reference in New Issue
Block a user