tox: run tests against python 3 (#36515)
This commit is contained in:
parent
de96b7d721
commit
279abb7753
|
@ -4,9 +4,9 @@ pipeline {
|
||||||
agent any
|
agent any
|
||||||
options { disableConcurrentBuilds() }
|
options { disableConcurrentBuilds() }
|
||||||
stages {
|
stages {
|
||||||
stage('Unit Tests') {
|
stage('Unit Tests (Python 2)') {
|
||||||
steps {
|
steps {
|
||||||
sh 'tox -r'
|
sh 'tox -r -e py2-pylint-coverage'
|
||||||
}
|
}
|
||||||
post {
|
post {
|
||||||
always {
|
always {
|
||||||
|
@ -20,6 +20,11 @@ pipeline {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
stage('Unit Tests (Python 3)') {
|
||||||
|
steps {
|
||||||
|
sh 'tox -r -e py3'
|
||||||
|
}
|
||||||
|
}
|
||||||
stage('Packaging') {
|
stage('Packaging') {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
|
|
8
tox.ini
8
tox.ini
|
@ -1,6 +1,6 @@
|
||||||
[tox]
|
[tox]
|
||||||
toxworkdir = {env:TMPDIR:/tmp}/tox-{env:USER}/wcs/{env:BRANCH_NAME:}
|
toxworkdir = {env:TMPDIR:/tmp}/tox-{env:USER}/wcs/{env:BRANCH_NAME:}
|
||||||
envlist = py2-pylint-coverage
|
envlist = py2-pylint-coverage,py3
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
sitepackages = true
|
sitepackages = true
|
||||||
|
@ -16,7 +16,8 @@ setenv =
|
||||||
passenv =
|
passenv =
|
||||||
USER
|
USER
|
||||||
deps =
|
deps =
|
||||||
pytest
|
py2: pytest
|
||||||
|
py3: pytest>=3.6,<5
|
||||||
pytest-mock
|
pytest-mock
|
||||||
pytest-cov
|
pytest-cov
|
||||||
pytest-django
|
pytest-django
|
||||||
|
@ -29,6 +30,7 @@ deps =
|
||||||
django-ratelimit<3
|
django-ratelimit<3
|
||||||
pyproj
|
pyproj
|
||||||
pylint<1.8
|
pylint<1.8
|
||||||
|
py3: Quixote>=3.0
|
||||||
commands =
|
commands =
|
||||||
py.test {env:COVERAGE:} {posargs:tests/}
|
py.test -v {env:COVERAGE:} {posargs:tests/}
|
||||||
pylint: ./pylint.sh wcs/
|
pylint: ./pylint.sh wcs/
|
||||||
|
|
Loading…
Reference in New Issue