From 47963d1e5ae486012be8e578e8424d00c90f3bd5 Mon Sep 17 00:00:00 2001 From: "Karl O. Pinc" Date: Tue, 6 Nov 2018 21:06:03 -0600 Subject: [PATCH] Add Pyramid's testing requirements --- Makefile | 20 +++++++++++++++----- setup.py | 16 +++++++++++----- 2 files changed, 26 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index b1ff9c7..ea3ec10 100644 --- a/Makefile +++ b/Makefile @@ -120,7 +120,9 @@ devel/testenv: devel || ( ${VIRTUALENV} devel/testenv ; \ devel/testenv/bin/pip install --upgrade pip ; \ devel/testenv/bin/pip install --upgrade setuptools ; \ - devel/testenv/bin/pip install tox) + devel/testenv/bin/pip install tox ; \ + devel/testenv/bin/pip install -e '.[testing]' ; \ + ) update_testenv: devel/testenv devel/testenv/bin/pip -U @@ -142,10 +144,14 @@ devel/pytest: devel dist devel/pytest/bin/pip install --upgrade wheel ; \ devel/pytest/bin/pip install dist/pgwui_common-*.tar.gz ; \ devel/pytest/bin/pip install flake8 ; \ - devel/pytest/bin/pip install pytest-cov ; ) \ + devel/pytest/bin/pip install pytest-cov ; \ + devel/pytest/bin/pip install -e '.[testing]' ; \ + ) \ else \ ( devel/pytest/bin/pip uninstall -y pgwui_common ; \ - devel/pytest/bin/pip install dist/pgwui_common-*.tar.gz ) ; \ + devel/pytest/bin/pip install dist/pgwui_common-*.tar.gz ; \ + devel/pytest/bin/pip install -e '.[testing]' ; \ + ) ; \ fi .PHONY: check @@ -160,10 +166,14 @@ devel/pudb: devel dist devel/pudb/bin/pip install --upgrade setuptools ; \ devel/pytest/bin/pip install --upgrade wheel ; \ devel/pudb/bin/pip install dist/pgwui_common-*.tar.gz ; \ - devel/pudb/bin/pip install pudb ; ) \ + devel/pudb/bin/pip install -e '.[testing]' ; \ + devel/pudb/bin/pip install pudb ; \ + ) \ else \ ( devel/pudb/bin/pip uninstall -y pgwui_common ; \ - devel/pudb/bin/pip install dist/pgwui_common-*.tar.gz ) ; \ + devel/pudb/bin/pip install -e '.[testing]' ; \ + devel/pudb/bin/pip install dist/pgwui_common-*.tar.gz ; \ + ) ; \ fi .PHONY: pudb diff --git a/setup.py b/setup.py index c52fd72..14651d2 100644 --- a/setup.py +++ b/setup.py @@ -57,6 +57,13 @@ with open(path.join(here, 'src', 'pgwui_common', 'VERSION'), # Get the long description from the README file long_description = filter_readme() +# Pyramid testing requirements +tests_require = [ + 'WebTest >= 1.3.1', # py3 compat + 'pytest>=3.7.4', + 'pytest-cov', +] + setup( name='pgwui_common', @@ -140,11 +147,10 @@ setup( # List additional groups of dependencies here (e.g. development # dependencies). You can install these using the following syntax, # for example: - # $ pip install -e .[dev,test] - # extras_require={ - # 'dev': ['check-manifest'], - # 'test': ['coverage'], - # }, + # $ pip install -e .[testing] + extras_require={ + 'testing': tests_require, + }, # If there are data files included in your packages that need to be # installed, specify them here. -- 2.34.1