aboutsummaryrefslogtreecommitdiffstats
path: root/community/py3-pyfakefs/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/py3-pyfakefs/APKBUILD')
-rw-r--r--community/py3-pyfakefs/APKBUILD36
1 files changed, 28 insertions, 8 deletions
diff --git a/community/py3-pyfakefs/APKBUILD b/community/py3-pyfakefs/APKBUILD
index d56bab5b44f..6ccca5ef661 100644
--- a/community/py3-pyfakefs/APKBUILD
+++ b/community/py3-pyfakefs/APKBUILD
@@ -1,30 +1,50 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=py3-pyfakefs
_pkgname=${pkgname#py3-}
-pkgver=4.5.1
+pkgver=5.3.5
pkgrel=0
pkgdesc="fake file system that mocks the Python file system modules"
-options="!check" # flaky tests
-url="https://github.com/jmcgeheeiv/pyfakefs/"
+url="https://github.com/pytest-dev/pyfakefs/"
arch="noarch"
license="Apache-2.0"
depends="python3"
-makedepends="py3-setuptools"
+makedepends="
+ py3-gpep517
+ py3-setuptools
+ py3-wheel
+ "
+checkdepends="py3-pytest"
+subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir"/$_pkgname-$pkgver
+case "$CARCH" in
+# fails on builder currently
+aarch64|armhf|armv7) _test_filter='not test_chown_follow_symlink and not test_chown_no_follow_symlink' ;;
+esac
+
build() {
- python3 setup.py build
+ gpep517 build-wheel \
+ --wheel-dir .dist \
+ --output-fd 3 3>&1 >&2
}
check() {
- python3 setup.py test
+ python3 -m venv --clear --without-pip --system-site-packages .testenv
+ .testenv/bin/python3 -m installer .dist/*.whl
+
+ # pytest_fixture_test.py: needs currently unpackaged 'undefined' module
+ .testenv/bin/python3 -m pytest \
+ --ignore pyfakefs/pytest_tests/pytest_fixture_test.py \
+ -k "$_test_filter"
}
package() {
- python3 setup.py install --prefix=/usr --root="$pkgdir"
+ python3 -m installer -d "$pkgdir" \
+ .dist/*.whl
+ rm -r "$pkgdir"/usr/lib/python*/site-packages/pyfakefs/*tests
}
sha512sums="
-04b4c2e487a4ad59be59811fd2d922e32878c3a06a2c21fed3a7fe999431eb5287c0f50b0af8e91e8bf27225e2417560fa40ea325459f5a72004faf7218caf7b pyfakefs-4.5.1.tar.gz
+c477f3f6e2754100f320a9a966cdb69ec0845c68ce9428bbb72bf723d646ef007c94ff17336170a7861e45f83a5e8d7fbd72460345b7565570ab5494652d75c7 pyfakefs-5.3.5.tar.gz
"