git: f4e48425837f - main - science/py-libgetar: Fix tests

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Mon, 27 Jun 2022 22:39:45 UTC
The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=f4e48425837f31200de79fe30628c8fa5985c20e

commit f4e48425837f31200de79fe30628c8fa5985c20e
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2022-06-27 22:36:50 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2022-06-27 22:39:42 +0000

    science/py-libgetar: Fix tests
---
 science/py-libgetar/Makefile | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/science/py-libgetar/Makefile b/science/py-libgetar/Makefile
index df16044727d8..aef8a63fffd9 100644
--- a/science/py-libgetar/Makefile
+++ b/science/py-libgetar/Makefile
@@ -16,14 +16,17 @@ BUILD_DEPENDS=	${PY_DEPENDS}
 RUN_DEPENDS=	${PY_DEPENDS}
 
 USES=		python
-USE_PYTHON=	distutils cython autoplist pytest # tests fail, see https://github.com/glotzerlab/libgetar/issues/29
+USE_PYTHON=	distutils cython autoplist
 
 USE_GITHUB=	yes
 GH_ACCOUNT=	glotzerlab
 
-TEST_ENV=      ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
+TEST_ENV=	${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
 
 post-install:
 	@${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/gtar/_gtar${PYTHON_EXT_SUFFIX}.so
 
+do-test:
+	@cd ${WRKSRC}/test && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m unittest discover
+
 .include <bsd.port.mk>