testing/py3-junit-xml: build with gpep517

This commit is contained in:
ptrcnull 2024-08-05 22:45:49 +02:00
parent 73769a8ba0
commit 2ff19bbc02

View File

@ -2,29 +2,34 @@
pkgname=py3-junit-xml pkgname=py3-junit-xml
_pkgname=junit-xml _pkgname=junit-xml
pkgver=1.9 pkgver=1.9
pkgrel=2 pkgrel=3
pkgdesc="Creates JUnit XML test result documents that can be read by tools such as Jenkins" pkgdesc="Creates JUnit XML test result documents that can be read by tools such as Jenkins"
options="!check" # 1 test fail options="!check" # 1 test fail
url="https://pypi.org/project/junit-xml" url="https://pypi.org/project/junit-xml"
arch="noarch" arch="noarch"
license="MIT" license="MIT"
depends="py3-six" depends="py3-six"
makedepends="py3-setuptools" makedepends="py3-setuptools py3-gpep517"
checkdepends="py3-pytest" checkdepends="py3-pytest"
subpackages="$pkgname-pyc" subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir"/$_pkgname-$pkgver builddir="$srcdir"/$_pkgname-$pkgver
build() { build() {
python3 setup.py build gpep517 build-wheel \
--wheel-dir .dist \
--output-fd 3 3>&1 >&2
} }
check() { check() {
py.test-3 python3 -m venv --clear --without-pip --system-site-packages .testenv
gpep517 install-wheel --destdir .testenv --prefix '' .dist/*.whl
.testenv/bin/python3 -m pytest
} }
package() { package() {
python3 setup.py install --skip-build --root="$pkgdir" gpep517 install-wheel --destdir "$pkgdir" \
.dist/*.whl
} }
sha512sums=" sha512sums="