summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNuno Teixeira <eduardo@FreeBSD.org>2025-01-12 10:58:08 +0000
committerNuno Teixeira <eduardo@FreeBSD.org>2025-01-12 11:05:10 +0000
commitb725b1d73988e8288a7d95d0b2ccd27cc3de82bd (patch)
treeaaf3a03616092050e59f1bb57ade62fbec07d953
parentscience/py-rmsd: update 1.5.1 → 1.6.3 (diff)
editors/retext: Improve tests
Use display:test instead of reinventing the wheel... Thank you, jbeich@, for informing me about this useful feature.
-rw-r--r--editors/retext/Makefile17
1 files changed, 4 insertions, 13 deletions
diff --git a/editors/retext/Makefile b/editors/retext/Makefile
index de6637ec2dd8..8a5a983e5d0e 100644
--- a/editors/retext/Makefile
+++ b/editors/retext/Makefile
@@ -1,5 +1,6 @@
PORTNAME= ReText
DISTVERSION= 8.1.0
+PORTREVISION= 1
CATEGORIES= editors
MASTER_SITES= PYPI
DISTNAME= retext-${DISTVERSION}
@@ -19,23 +20,13 @@ RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}docutils>=0:textproc/py-docutils@${PY_FLAVOR
${PYTHON_PKGNAMEPREFIX}markups>=4.0.0:textproc/py-markups@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pygments>=0:textproc/py-pygments@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}python-markdown-math>=0.6:textproc/py-python-markdown-math@${PY_FLAVOR}
-TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pymdown-extensions>0:textproc/py-pymdown-extensions@${PY_FLAVOR} \
- ${PYTHON_PKGNAMEPREFIX}pytest>=0:devel/py-pytest@${PY_FLAVOR} \
- Xvfb:x11-servers/xorg-server@xvfb
+TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pymdown-extensions>0:textproc/py-pymdown-extensions@${PY_FLAVOR}
-USES= desktop-file-utils pyqt:6 python:3.9+ qt:6
+USES= desktop-file-utils display:test pyqt:6 python:3.9+ qt:6
USE_PYQT= pyqt6:run
-USE_PYTHON= autoplist noflavors pep517
+USE_PYTHON= autoplist noflavors pep517 pytest
USE_QT= tools:build
NO_ARCH= yes
-# Run tests in Xvfb using an approach to upstream CI:
-# https://github.com/retext-project/retext/blob/2ef7142e9422e8423e168a7ab30f8e491510f9b6/.github/workflows/main.yml#L59
-# run: xvfb-run -a -s "-screen 0 1024x768x24" python -m unittest discover -s tests -v
-do-test:
- Xvfb :1 -screen 0 1024x768x24 & \
- cd ${WRKSRC} && ${SETENV} DISPLAY=:1 ${PYTHON_CMD} -m pytest -rs -v ; \
- killall -v Xvfb
-
.include <bsd.port.mk>