aboutsummaryrefslogtreecommitdiffstats
path: root/testing/pytest-expect/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'testing/pytest-expect/APKBUILD')
-rw-r--r--testing/pytest-expect/APKBUILD52
1 files changed, 52 insertions, 0 deletions
diff --git a/testing/pytest-expect/APKBUILD b/testing/pytest-expect/APKBUILD
new file mode 100644
index 0000000000..4bb0fc9452
--- /dev/null
+++ b/testing/pytest-expect/APKBUILD
@@ -0,0 +1,52 @@
+# Contributor: Stefan Wagner <stw@bit-strickerei.de>
+# Maintainer: Stefan Wagner <stw@bit-strickerei.de>
+pkgname=pytest-expect
+pkgver=1.1.0
+pkgrel=0
+pkgdesc="py.test plugin that stores test expectations."
+url="https://github.com/gsnedders/pytest-expect"
+arch="noarch"
+license="MIT"
+depends="pytest py-u-msgpack"
+makedepends="python2-dev python3-dev py-setuptools"
+subpackages="py3-$pkgname:_py3 py2-$pkgname:_py2"
+source="$pkgname-$pkgver.tar.gz::https://github.com/gsnedders/$pkgname/archive/$pkgver.tar.gz"
+builddir="$srcdir/$pkgname-$pkgver"
+
+build() {
+ cd "$builddir"
+ python2 setup.py build
+ python3 setup.py build
+}
+
+check() {
+ cd "$builddir"
+ python2 setup.py test
+ python3 setup.py test
+}
+
+package() {
+ mkdir -p "$pkgdir"
+}
+
+_py2() {
+ depends="${depends//py-/py2-}"
+ _py python2
+}
+
+_py3() {
+ depends="${depends//py-/py3-}"
+ _py python3
+}
+
+_py() {
+ local python=$1
+ pkgdesc="$pkgdesc - $python"
+ depends="$depends $python"
+ install_if="$pkgname=$pkgver-r$pkgrel $python"
+
+ cd "$builddir"
+ $python setup.py install --prefix=/usr --root="$subpkgdir"
+}
+
+sha512sums="dbef3c394e974663179e91ca3cd6f096fdb055693b3e540dd0f27d6bf59a5c7298144598eb069f8f0acddd82ecce0bdce14ccd25728eb6a024d41895403e5144 pytest-expect-1.1.0.tar.gz"