| 1 | # Contributor: Johannes Marbach <[email protected]> |
| 2 | # Maintainer: Oliver Smith <[email protected]> |
| 3 | pkgname=py3-pytest-httpserver |
| 4 | pkgver=1.2.0 |
| 5 | pkgrel=0 |
| 6 | pkgdesc="Http server for pytest to test http clients" |
| 7 | url="https://github.com/csernazs/pytest-httpserver" |
| 8 | arch="noarch" |
| 9 | license="MIT" |
| 10 | depends="python3 py3-werkzeug" |
| 11 | makedepends="py3-gpep517 py3-installer py3-poetry-core" |
| 12 | checkdepends="py3-pytest py3-pytest-runner py3-requests py3-toml" |
| 13 | subpackages="$pkgname-pyc" |
| 14 | source="$pkgname-$pkgver.tar.gz::https://github.com/csernazs/pytest-httpserver/archive/$pkgver.tar.gz" |
| 15 | builddir="$srcdir/pytest-httpserver-$pkgver" |
| 16 | |
| 17 | build() { |
| 18 | gpep517 build-wheel \ |
| 19 | --wheel-dir .dist \ |
| 20 | --output-fd 3 3>&1 >&2 |
| 21 | } |
| 22 | |
| 23 | check() { |
| 24 | python3 -m venv --clear --without-pip --system-site-packages test-env |
| 25 | test-env/bin/python3 -m installer .dist/pytest_httpserver-*.whl |
| 26 | test-env/bin/python3 -m pytest \ |
| 27 | -k 'not test_ipv6' # Ever thought about gardening instead? |
| 28 | } |
| 29 | |
| 30 | package() { |
| 31 | python3 -m installer -d "$pkgdir" \ |
| 32 | .dist/pytest_httpserver-*.whl |
| 33 | } |
| 34 | |
| 35 | sha512sums=" |
| 36 | c4fc70f9f1c9e21947c7460179322b45e44b2b556960e305ad845f7f4683206b8b2880b67ed2554a71f7e8c906bcbd4d96d024d602f098597abd69ad15c88254 py3-pytest-httpserver-1.2.0.tar.gz |
| 37 | " |