# Contributor: Mika Havela <mika.havela@gmail.com>
# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer:
pkgname=py3-genshi
pkgver=0.7.9
pkgrel=0
pkgdesc="Python toolkit for stream-based generation of output for the web"
url="https://genshi.edgewall.org/"
arch="all"
license="MIT"
makedepends="
	py3-gpep517
	py3-setuptools
	py3-wheel
	python3-dev
	"
checkdepends="
	py3-pytest
	py3-six
	"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/edgewall/genshi/archive/$pkgver.tar.gz"
builddir="$srcdir/genshi-$pkgver"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	python3 -m venv --clear --without-pip --system-site-packages .testenv
	.testenv/bin/python3 -m installer .dist/*.whl
	.testenv/bin/python3 -m pytest
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
4b0b238ea8de5d79091c4c6704ef6f09039481a520fd5795ad60e7b83522b80704fb98d75570c5f2733d951151ee5258c9864155b9d322a8aeb1e4cdfbfbba98  py3-genshi-0.7.9.tar.gz
"
