blob: 99aa7adff309600d04ac4de799dc543e7ec4e53d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=py3-pytest-black
pkgver=0.3.12
pkgrel=3
pkgdesc="pytest plugin to enable format checking with black"
url="https://github.com/shopkeep/pytest-black"
arch="noarch"
license="MIT"
depends="python3 py3-pytest black py3-toml"
makedepends="py3-setuptools py3-setuptools_scm"
source="https://pypi.python.org/packages/source/p/pytest-black/pytest-black-$pkgver.tar.gz"
builddir="$srcdir/pytest-black-$pkgver"
build() {
python3 setup.py build
}
check() {
# Hack entry point by installing it
python3 setup.py install --root="$PWD/tmp_install"
# delesect tests that fails with pytest>=6.2
PYTHONPATH="$PWD/tmp_install/usr/lib/python3.8/site-packages:$PYTHONPATH" pytest -v \
--deselect tests/test_black.py::test_exclude \
--deselect tests/test_black.py::test_exclude_folder \
--deselect tests/test_black.py::test_include
}
package() {
python3 setup.py install --skip-build --root="$pkgdir"
}
sha512sums="3bf6cc27a872f351ad1b49650d5b4758d14fea65627008204d2f45557c61e597def6aa6eb6f61fb439ebf783b4df997a3c4320ccbb65ee99d0dd9eaa6fde05bd pytest-black-0.3.12.tar.gz"
|