|
1 | 1 | [tox] |
2 | 2 | envlist = |
3 | | - py3{6,7,8,9} |
4 | | - py3{6,7,8,9}-functional |
| 3 | + py3{10,11,12,13}{,-functional} |
| 4 | + coverage |
5 | 5 |
|
6 | 6 | [testenv] |
7 | | -passenv = TOXENV,CI,TRAVIS,TRAVIS_* |
8 | | -usedevelop = True |
9 | | -install_command = pip install -U {opts} {packages} |
10 | | -deps = -r{toxinidir}/test-requirements.txt |
11 | | - -r{toxinidir}/requirements.txt |
| 7 | +use_develop = true |
| 8 | +deps = |
| 9 | + -r{toxinidir}/test-requirements.txt |
| 10 | + -r{toxinidir}/requirements.txt |
| 11 | +setenv = |
| 12 | + # Unset KUBECONFIG to prevent tests from picking up local cluster configuration |
| 13 | + KUBECONFIG = {envtmpdir}/.kubeconfig-nonexistent |
12 | 14 | commands = |
13 | | - python -V |
14 | | - !functional: pytest -vvv -s {env:_TOX_COVERAGE_RUN:} --ignore=kubernetes/e2e_test |
15 | | - functional: {toxinidir}/scripts/kube-init.sh pytest -vvv -s [] |
16 | | - coverage: python -m coverage xml |
| 15 | + python -V |
| 16 | + pytest -vvv -s {env:_TOX_COVERAGE_RUN:} --ignore=kubernetes/e2e_test {posargs} |
| 17 | + |
| 18 | +[testenv:py3{10,11,12,13}-functional] |
17 | 19 | setenv = |
18 | | - coverage: _TOX_COVERAGE_RUN=--cov=kubernetes/watch --cov=kubernetes/config |
| 20 | +allowlist_externals = |
| 21 | + scripts/kube-init.sh |
| 22 | +commands = |
| 23 | + {toxinidir}/scripts/kube-init.sh pytest -vvv -s [] {posargs} |
19 | 24 |
|
20 | | -[testenv:docs] |
| 25 | +[testenv:coverage] |
| 26 | +setenv = |
| 27 | + {[testenv]setenv} |
| 28 | + _TOX_COVERAGE_RUN=--cov=kubernetes/watch --cov=kubernetes/config |
21 | 29 | commands = |
22 | | - python setup.py build_sphinx |
| 30 | + {[testenv:coverage]commands} |
| 31 | + python -m coverage xml |
23 | 32 |
|
24 | | -[testenv:update-pycodestyle] |
| 33 | +[testenv:docs] |
| 34 | +deps = |
| 35 | + -r{toxinidir}/doc/requirements.txt |
25 | 36 | commands = |
26 | | - {toxinidir}/scripts/update-pycodestyle.sh |
| 37 | + sphinx-build -W --keep-going -b html -j auto doc/source/ doc/build/html |
0 commit comments