kmos c45cd79fc7 Add RUN_DEPENDS to TEST_DEPENDS automatically for ports using the
lang/python port module. I've not yet come up with a port that
would not need this and one can always set MODPY_TESTDEP to "no"
to prevent the module from touching TEST_DEPENDS.

Idea from afresh1 who pointed out the cpan module already does this.

aja "I support this move."

OK sthen@
2019-05-15 12:04:34 +00:00

36 lines
832 B
Makefile

# $OpenBSD: Makefile,v 1.2 2019/05/15 12:04:37 kmos Exp $
COMMENT = py.test plugin to validate Jupyter notebooks
MODPY_EGG_VERSION = 0.9.1
DISTNAME = nbval-${MODPY_EGG_VERSION}
PKGNAME = py-${DISTNAME}
CATEGORIES = devel
# BSD
PERMIT_PACKAGE_CDROM = Yes
MODULES = lang/python
MODPY_PI = Yes
MODPY_SETUPTOOLS = Yes
MODPY_PYTEST = Yes
MODPY_PYTEST_ARGS = -v --current-env
RUN_DEPENDS = devel/py-ipykernel${MODPY_FLAVOR} \
devel/py-jupyter_client${MODPY_FLAVOR} \
devel/py-nbformat${MODPY_FLAVOR} \
devel/py-six${MODPY_FLAVOR} \
devel/py-test-cov${MODPY_FLAVOR}
TEST_DEPENDS = devel/py-nbval${MODPY_FLAVOR} \
math/py-sympy${MODPY_FLAVOR}
FLAVORS = python3
FLAVOR ?=
post-patch:
sed -i 's,py.test,py.test${MODPY_BIN_SUFFIX},' \
${WRKSRC}/tests/test_unit_tests_in_notebooks.py
.include <bsd.port.mk>