Skip to content

Commit

Permalink
security/py-vici: fix tests
Browse files Browse the repository at this point in the history
Switch to USES=pytest, fix test depends and run pytest directly
instead of through tox, which hinders testing by trying to use
unrelated interpreters and install dependencies with pip.

Reported by:	reprise
Approved by:	portmgr blanket
  • Loading branch information
AMDmi3 committed Apr 27, 2022
1 parent 0a45234 commit 04ffc11
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions security/py-vici/Makefile
Expand Up @@ -10,16 +10,12 @@ COMMENT= Native Python interface for strongSwan's VICI protocol
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE

TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pycodestyle>0:devel/py-pycodestyle@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}tox>0:devel/py-tox@${PY_FLAVOR}
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest-pycodestyle>0:devel/py-pytest-pycodestyle@${PY_FLAVOR}

USES= python:3.6+
USES= python:3.6+ pytest
USE_PYTHON= autoplist concurrent distutils
PYTEST_ARGS= --pycodestyle

NO_ARCH= yes

do-test: # skip non installed python versions in the tests (because flavors)
cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m tox --skip-missing-interpreters

.include <bsd.port.mk>

0 comments on commit 04ffc11

Please sign in to comment.