|
1 | 1 | [tox] |
2 | | -envlist = py36,coverage,coveralls,packaging,docs,flake8 |
| 2 | +envlist = py36,coverage,coveralls,docs,flake8,packaging,dist |
3 | 3 | skip_missing_interpreters = True |
4 | 4 | ignore_basepython_conflict = True |
5 | 5 |
|
6 | 6 | [testenv] |
7 | 7 | description = default settings for unspecified tests |
8 | | -usedevelop = True |
| 8 | +usedevelop = False |
| 9 | +skip_install = False |
9 | 10 | passenv = * |
10 | 11 | basepython = python3.6 |
11 | | -deps = -r{toxinidir}/tools/tests-requirements.txt |
| 12 | + |
| 13 | +[testenv:py27] |
| 14 | +deps = |
| 15 | + -r{toxinidir}/tools/tests-requirements.txt |
| 16 | +commands = |
| 17 | + pytest tests/ --cov=src/pyDataverse --basetemp={envtmpdir} |
| 18 | + |
| 19 | +[testenv:py34] |
| 20 | +deps = |
| 21 | + -r{toxinidir}/tools/tests-requirements.txt |
| 22 | +commands = |
| 23 | + pytest tests/ --cov=src/pyDataverse --basetemp={envtmpdir} |
| 24 | + |
| 25 | +[testenv:py35] |
| 26 | +deps = |
| 27 | + -r{toxinidir}/tools/tests-requirements.txt |
| 28 | +commands = |
| 29 | + pytest tests/ --cov=src/pyDataverse --basetemp={envtmpdir} |
| 30 | + |
| 31 | +[testenv:py36] |
| 32 | +deps = |
| 33 | + -r{toxinidir}/tools/tests-requirements.txt |
| 34 | +commands = |
| 35 | + pytest tests/ --cov=src/pyDataverse --basetemp={envtmpdir} |
| 36 | + |
| 37 | +[testenv:py37] |
| 38 | +deps = |
| 39 | + -r{toxinidir}/tools/tests-requirements.txt |
12 | 40 | commands = |
13 | 41 | pytest tests/ --cov=src/pyDataverse --basetemp={envtmpdir} |
14 | 42 |
|
15 | 43 | [testenv:coverage] |
16 | 44 | description = create report for coverage |
17 | | -basepython = python3.6 |
18 | | -deps = -r{toxinidir}/tools/tests-requirements.txt |
| 45 | +deps = |
| 46 | + -r{toxinidir}/tools/tests-requirements.txt |
19 | 47 | commands = |
20 | 48 | pytest tests/ --cov=src/pyDataverse --cov-report=term-missing --cov-report=xml --cov-report=html |
21 | 49 |
|
22 | 50 | [testenv:coveralls] |
23 | 51 | description = create reports for coveralls |
24 | | -basepython = python3.6 |
25 | | -deps = -r{toxinidir}/tools/tests-requirements.txt |
| 52 | +deps = |
| 53 | + -r{toxinidir}/tools/tests-requirements.txt |
26 | 54 | commands = |
27 | 55 | pytest tests/ --doctest-modules -v --cov=src/pyDataverse |
28 | 56 |
|
29 | | -[testenv:packaging] |
30 | | -description = check packaging with twine |
31 | | -usedevelop = True |
32 | | -basepython = python3.6 |
33 | | -skip_install = True |
34 | | -deps = -r{toxinidir}/tools/packaging-requirements.txt |
35 | | -commands = |
36 | | - twine check -h |
37 | | - |
38 | 57 | [flake8] |
39 | 58 | exclude = |
40 | | - src/pyDataverse/docs/source/conf.py |
| 59 | + src/pyDataverse/docs/source/conf.py |
| 60 | + .tox |
| 61 | + .egg |
41 | 62 |
|
42 | 63 | [testenv:flake8] |
43 | 64 | description = flake8 for style guide testing |
44 | | -usedevelop = True |
45 | | -basepython = python3.6 |
46 | | -deps = -r{toxinidir}/tools/lint-requirements.txt |
| 65 | +deps = |
| 66 | + -r{toxinidir}/tools/lint-requirements.txt |
47 | 67 | commands = |
48 | 68 | flake8 src/pyDataverse/ |
49 | 69 | flake8 tests/ |
50 | 70 | isort --check-only --diff src/pyDataverse |
51 | | -skip_install = true |
52 | 71 |
|
53 | 72 | [testenv:docs] |
54 | 73 | description = invoke sphinx-build to build the HTML docs |
55 | | -basepython = python3.6 |
56 | | -deps = -r{toxinidir}/tools/docs-requirements.txt |
| 74 | +deps = |
| 75 | + -r{toxinidir}/tools/docs-requirements.txt |
57 | 76 | commands = |
58 | 77 | sphinx-build -d src/pyDataverse/docs/build/docs_doctree src/pyDataverse/docs/source docs/build/html --color -b html {posargs} |
| 78 | + |
| 79 | +[testenv:packaging] |
| 80 | +description = check packaging with twine |
| 81 | +skip_install = True |
| 82 | +recreate = True |
| 83 | +deps = |
| 84 | + -r{toxinidir}/tools/packaging-requirements.txt |
| 85 | +commands = |
| 86 | + python setup.py sdist bdist_wheel |
| 87 | + twine check dist/* |
| 88 | + |
| 89 | +[testenv:dist] |
| 90 | +description = install from dist |
| 91 | +recreate = True |
| 92 | +commands = |
| 93 | + pip freeze |
| 94 | + python -c "import pyDataverse; print(pyDataverse.__name__); print(pyDataverse.__version__)" |
| 95 | + |
| 96 | +[testenv:pypitest] |
| 97 | +description = install from test pypi |
| 98 | +skip_install = True |
| 99 | +recreate = True |
| 100 | +commands = |
| 101 | + pip install --index-url https://test.pypi.org/simple/ pyDataverse |
| 102 | + pip freeze |
0 commit comments