1 # Maintainer: David Runge <dvzrv@archlinux.org>
4 pkgname=python-diff-cover
7 pkgdesc="Automatically find diff lines that need test coverage"
9 url="https://github.com/Bachmann1234/diff_cover"
11 depends=(python-chardet python-jinja python-pluggy python-pygments)
12 makedepends=(python-build python-installer python-poetry-core python-wheel)
13 checkdepends=(python-pytest python-pytest-mock python-tomli)
14 optdepends=('python-tomli: for TOML support')
15 source=(https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz{,.asc})
16 sha512sums=('3e3455fa89873554e0912a2bdf855fcc91a52ae801c1af80e4e32547a0fd5da8d5724eadddb5f7874b3dbf7f206c14b185eea4938de09dd03e72c29613a4cb1b'
18 b2sums=('6f6743bca81a2f3d893a19336a44d7638659eb065f31220dd74e58f063babd0d5fe49b4c729ed1c376afeabe12ec3f1996c19ac315bd08aabe8381e7dcccf675'
20 validpgpkeys=('54CAEABCAC2956D407348256972401BDE60128CB') # Matt Bachmann <matt.bachmann@lola.com>
24 python -m build --wheel --no-isolation
28 local _site_packages=$(python -c "import site; print(site.getsitepackages()[0])")
31 # install to temporary location, as importlib is used
32 python -m installer --destdir=test_dir dist/*.whl
33 export PYTHONPATH="test_dir/$_site_packages:$PYTHONPATH"
34 # ignore integration and code style checks
35 pytest -vv --ignore 'tests/test_integration.py' --ignore 'tests/test_violations_reporter.py' --ignore 'tests/test_clover_violations_reporter.py'
40 python -m installer --destdir="$pkgdir" dist/*.whl
41 install -vDm 644 README.rst -t "$pkgdir/usr/share/doc/$pkgname/"