Skip to content
Snippets Groups Projects
Commit 14eebf54 authored by Matthew Seaman's avatar Matthew Seaman
Browse files

textproc/py-wcmatch: Switch to USE_PYTHON= pep517 pytest

Use the system provided mechanisms for pep517 and pytest rather than
rolling our own.

Ignore widows specific tests.

Only changes to the build system with no functional effect on the built
package, so no version bump.
parent fb22e1c2
No related branches found
No related tags found
No related merge requests found
......@@ -15,31 +15,21 @@ BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=0.21.1:devel/py-hatchling@${PY_
${PYTHON_PKGNAMEPREFIX}pip>=22.2:devel/py-pip@${PY_FLAVOR}
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}bracex>=2.1.1:textproc/py-bracex@${PY_FLAVOR}
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pytest-cov>0:devel/py-pytest-cov@${PY_FLAVOR} \
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest-cov>0:devel/py-pytest-cov@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}coverage>0:devel/py-coverage@${PY_FLAVOR}
USES= python:3.7+
USE_PYTHON= flavors
USE_PYTHON= flavors pep517 pytest
# PYTHON_EXT_SUFFIX could be used here, except that it is
# special-cased for python3.7 which we don't want.
PYCACHE_SUFFIX= .cpython-${PYTHON_SUFFIX}.pyc
PLIST_SUB+= PORTVERSION=${PORTVERSION} PYCACHE_SUFFIX=${PYCACHE_SUFFIX}
# Windows specific tests
PYTEST_IGNORED_TESTS= test_escape_windows \
test_norm_windows \
test_escape_windows \
test_drive_insensitive \
test_drive_sensitive \
test_root_win \
test_glob_match_real_ignore_forceunix
NO_ARCH= yes
do-build:
cd ${WRKSRC} && ${PYTHON_CMD} -m hatchling build -t wheel
do-install:
${PYTHON_CMD} -m pip --no-cache-dir install --no-deps --ignore-installed \
--disable-pip-version-check --target ${STAGEDIR}${PYTHON_SITELIBDIR} \
${WRKSRC}/dist/${PORTNAME}-${PORTVERSION}-py3-none-any.whl
do-test:
@(cd ${TEST_WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m pytest)
.include <bsd.port.mk>
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/WHEEL
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/REQUESTED
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/RECORD
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/INSTALLER
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/direct_url.json
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/METADATA
%%PYTHON_LIBDIR%%/site-packages/wcmatch-%%PORTVERSION%%.dist-info/licenses/LICENSE.md
%%PYTHON_LIBDIR%%/site-packages/wcmatch/fnmatch.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/_wcparse.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/posix.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/_wcparse%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/glob%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/fnmatch%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/_wcmatch%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/wcmatch%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/pathlib%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/__init__%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/__meta__%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/posix%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__pycache__/util%%PYCACHE_SUFFIX%%
%%PYTHON_LIBDIR%%/site-packages/wcmatch/glob.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__init__.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/__meta__.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/util.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/_wcmatch.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/py.typed
%%PYTHON_LIBDIR%%/site-packages/wcmatch/pathlib.py
%%PYTHON_LIBDIR%%/site-packages/wcmatch/wcmatch.py
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment