setup: Move test dependencies into tox configuration.

pytest-runner, and generally doing this through setuptools, is deprecated.
A little sad, but understandable. Handle tests in tox as recommended.
This commit is contained in:
Brett Smith 2021-03-31 16:15:36 -04:00
parent 85f1aa66a6
commit c4561a0026
2 changed files with 8 additions and 11 deletions

View file

@ -14,4 +14,4 @@ The ``paypal-query`` tool is implemented in ``cliquery.py``. Other submodules li
Running tests Running tests
------------- -------------
Run ``./setup.py test`` to run unit tests. Run ``./setup.py typecheck`` to run the type checker. Run ``tox`` to run both on all supported Pythons. Run ``pytest`` to run unit tests. Run ``mypy paypal_rest`` to run the type checker. Run ``tox`` to run both on all supported Pythons.

View file

@ -13,10 +13,6 @@ project_urls =
Source = %(url)s Source = %(url)s
url = https://k.sfconservancy.org/NPO-Accounting/paypal_rest url = https://k.sfconservancy.org/NPO-Accounting/paypal_rest
[aliases]
test=pytest
typecheck=pytest --addopts="--mypy paypal_rest"
[bdist_wheel] [bdist_wheel]
universal = 1 universal = 1
@ -42,10 +38,6 @@ install_requires =
requests-oauthlib>=1.0 requests-oauthlib>=1.0
packages = find: packages = find:
python_requires = >=3.6 python_requires = >=3.6
tests_require =
mypy>=0.770
pytest
pytest-runner
[options.entry_points] [options.entry_points]
console_scripts = console_scripts =
@ -56,9 +48,14 @@ exclude =
tests tests
[testenv] [testenv]
deps =
mypy>=0.770
pytest>=3.0
pytest-mypy
commands = commands =
./setup.py test pytest
./setup.py typecheck pytest --mypy paypal_rest
[tool:pytest] [tool:pytest]
filterwarnings = filterwarnings =