pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel py-test-relaxed: added version 1.0.0



details:   https://anonhg.NetBSD.org/pkgsrc/rev/f20ee5337046
branches:  trunk
changeset: 371543:f20ee5337046
user:      adam <adam%pkgsrc.org@localhost>
date:      Wed Nov 15 09:23:17 2017 +0000

description:
py-test-relaxed: added version 1.0.0

pytest-relaxed provides 'relaxed' test discovery for pytest.

Has it ever felt strange to you that we put our tests in tests/, then name the
files test_foo.py, name the test classes TestFoo, and finally name the test
methods test_foo_bar? Especially when almost all of the code inside of tests/
is, well, tests?

This pytest plugin takes a page from the rest of Python, where you don't have
to explicitly note public module/class members, but only need to hint as to
which ones are private. By default, all files and objects pytest is told to
scan will be considered tests; to mark something as not-a-test, simply prefix
it with an underscore.

diffstat:

 devel/Makefile                               |   3 +-
 devel/py-test-relaxed/DESCR                  |  12 ++++++++++
 devel/py-test-relaxed/Makefile               |  20 ++++++++++++++++++
 devel/py-test-relaxed/PLIST                  |  31 ++++++++++++++++++++++++++++
 devel/py-test-relaxed/distinfo               |   7 ++++++
 devel/py-test-relaxed/patches/patch-setup.py |  21 ++++++++++++++++++
 6 files changed, 93 insertions(+), 1 deletions(-)

diffs (128 lines):

diff -r a4004d8ac82b -r f20ee5337046 devel/Makefile
--- a/devel/Makefile    Wed Nov 15 09:15:50 2017 +0000
+++ b/devel/Makefile    Wed Nov 15 09:23:17 2017 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2567 2017/11/08 21:35:46 wiz Exp $
+# $NetBSD: Makefile,v 1.2568 2017/11/15 09:23:17 adam Exp $
 #
 
 COMMENT=       Development utilities
@@ -2126,6 +2126,7 @@
 SUBDIR+=       py-test-isort
 SUBDIR+=       py-test-localserver
 SUBDIR+=       py-test-mock
+SUBDIR+=       py-test-relaxed
 SUBDIR+=       py-test-runner
 SUBDIR+=       py-test-timeout
 SUBDIR+=       py-test-utils
diff -r a4004d8ac82b -r f20ee5337046 devel/py-test-relaxed/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/py-test-relaxed/DESCR       Wed Nov 15 09:23:17 2017 +0000
@@ -0,0 +1,12 @@
+pytest-relaxed provides 'relaxed' test discovery for pytest.
+
+Has it ever felt strange to you that we put our tests in tests/, then name the
+files test_foo.py, name the test classes TestFoo, and finally name the test
+methods test_foo_bar? Especially when almost all of the code inside of tests/
+is, well, tests?
+
+This pytest plugin takes a page from the rest of Python, where you don't have
+to explicitly note public module/class members, but only need to hint as to
+which ones are private. By default, all files and objects pytest is told to
+scan will be considered tests; to mark something as not-a-test, simply prefix
+it with an underscore.
diff -r a4004d8ac82b -r f20ee5337046 devel/py-test-relaxed/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/py-test-relaxed/Makefile    Wed Nov 15 09:23:17 2017 +0000
@@ -0,0 +1,20 @@
+# $NetBSD: Makefile,v 1.1 2017/11/15 09:23:17 adam Exp $
+
+DISTNAME=      pytest-relaxed-1.0.0
+PKGNAME=       ${PYPKGPREFIX}-${DISTNAME:S/py//}
+CATEGORIES=    devel python
+MASTER_SITES=  ${MASTER_SITE_PYPI:=p/pytest-relaxed/}
+
+MAINTAINER=    pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=      https://github.com/bitprophet/pytest-relaxed
+COMMENT=       Relaxed test discovery/organization for pytest
+LICENSE=       modified-bsd
+
+DEPENDS+=      ${PYPKGPREFIX}-decorator>=4.0.0:../../devel/py-decorator
+DEPENDS+=      ${PYPKGPREFIX}-six>=1.0.0:../../lang/py-six
+DEPENDS+=      ${PYPKGPREFIX}-test>=3.0.0:../../devel/py-test
+
+USE_LANGUAGES= # none
+
+.include "../../lang/python/egg.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r a4004d8ac82b -r f20ee5337046 devel/py-test-relaxed/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/py-test-relaxed/PLIST       Wed Nov 15 09:23:17 2017 +0000
@@ -0,0 +1,31 @@
+@comment $NetBSD: PLIST,v 1.1 2017/11/15 09:23:17 adam Exp $
+${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
+${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
+${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
+${PYSITELIB}/${EGG_INFODIR}/entry_points.txt
+${PYSITELIB}/${EGG_INFODIR}/requires.txt
+${PYSITELIB}/${EGG_INFODIR}/top_level.txt
+${PYSITELIB}/pytest_relaxed/__init__.py
+${PYSITELIB}/pytest_relaxed/__init__.pyc
+${PYSITELIB}/pytest_relaxed/__init__.pyo
+${PYSITELIB}/pytest_relaxed/_version.py
+${PYSITELIB}/pytest_relaxed/_version.pyc
+${PYSITELIB}/pytest_relaxed/_version.pyo
+${PYSITELIB}/pytest_relaxed/classes.py
+${PYSITELIB}/pytest_relaxed/classes.pyc
+${PYSITELIB}/pytest_relaxed/classes.pyo
+${PYSITELIB}/pytest_relaxed/fixtures.py
+${PYSITELIB}/pytest_relaxed/fixtures.pyc
+${PYSITELIB}/pytest_relaxed/fixtures.pyo
+${PYSITELIB}/pytest_relaxed/plugin.py
+${PYSITELIB}/pytest_relaxed/plugin.pyc
+${PYSITELIB}/pytest_relaxed/plugin.pyo
+${PYSITELIB}/pytest_relaxed/raises.py
+${PYSITELIB}/pytest_relaxed/raises.pyc
+${PYSITELIB}/pytest_relaxed/raises.pyo
+${PYSITELIB}/pytest_relaxed/reporter.py
+${PYSITELIB}/pytest_relaxed/reporter.pyc
+${PYSITELIB}/pytest_relaxed/reporter.pyo
+${PYSITELIB}/pytest_relaxed/trap.py
+${PYSITELIB}/pytest_relaxed/trap.pyc
+${PYSITELIB}/pytest_relaxed/trap.pyo
diff -r a4004d8ac82b -r f20ee5337046 devel/py-test-relaxed/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/py-test-relaxed/distinfo    Wed Nov 15 09:23:17 2017 +0000
@@ -0,0 +1,7 @@
+$NetBSD: distinfo,v 1.1 2017/11/15 09:23:17 adam Exp $
+
+SHA1 (pytest-relaxed-1.0.0.tar.gz) = 3487df767afc96d2edf3d57758dda1363ebcd811
+RMD160 (pytest-relaxed-1.0.0.tar.gz) = 4732a4d06638bf11f403dae6bbed5513358d932f
+SHA512 (pytest-relaxed-1.0.0.tar.gz) = c97a512bd74666104a38324e4eb0b4afa0ab653d723506edfcd822630bed1364588b76ddca226cb0c8f630725f89b768073f790e92bd40d4fa6222cf28474203
+Size (pytest-relaxed-1.0.0.tar.gz) = 23786 bytes
+SHA1 (patch-setup.py) = c7f041172a497495edf2f97df735da9566e41acb
diff -r a4004d8ac82b -r f20ee5337046 devel/py-test-relaxed/patches/patch-setup.py
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/py-test-relaxed/patches/patch-setup.py      Wed Nov 15 09:23:17 2017 +0000
@@ -0,0 +1,21 @@
+$NetBSD: patch-setup.py,v 1.1 2017/11/15 09:23:17 adam Exp $
+
+Open README.rst with proper encoding.
+
+--- setup.py.orig      2017-10-19 03:09:37.000000000 +0000
++++ setup.py
+@@ -1,4 +1,5 @@
+ #!/usr/bin/env python
++import io
+ 
+ from setuptools import setup, find_packages
+ 
+@@ -19,7 +20,7 @@ setup(
+     url="https://github.com/bitprophet/pytest-relaxed";,
+     author='Jeff Forcier',
+     author_email='jeff%bitprophet.org@localhost',
+-    long_description="\n" + open('README.rst').read(),
++    long_description="\n" + io.open('README.rst', encoding='utf-8').read(),
+ 
+     packages=find_packages(),
+     entry_points={



Home | Main Index | Thread Index | Old Index