diff options
author | Stuart Cardall <developer@it-offshore.co.uk> | 2017-07-09 17:21:14 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2017-07-10 18:58:45 +0000 |
commit | 062d97789d0d4e037420e83c5f1349e7d062bc5d (patch) | |
tree | 0fd72298746a350ef394f5cf8f8b614580b66587 /testing/py-nosexcover | |
parent | c775efc38e1d4033a18c3a3c5571bac94e32042e (diff) | |
download | aports-062d97789d0d4e037420e83c5f1349e7d062bc5d.tar.bz2 aports-062d97789d0d4e037420e83c5f1349e7d062bc5d.tar.xz |
testing/py-nosexcover: new aport
Diffstat (limited to 'testing/py-nosexcover')
-rw-r--r-- | testing/py-nosexcover/APKBUILD | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/testing/py-nosexcover/APKBUILD b/testing/py-nosexcover/APKBUILD new file mode 100644 index 0000000000..a38834ba42 --- /dev/null +++ b/testing/py-nosexcover/APKBUILD @@ -0,0 +1,53 @@ +# Contributor: Stuart Cardall <developer@it-offshore.co.uk> +# Maintainer: Stuart Cardall <developer@it-offshore.co.uk> +pkgname=py-nosexcover +_pkgname=nose-xcover +pkgver=1.0.11 +pkgrel=0 +pkgdesc="Extends nose.plugins.cover to add Cobertura-style XML reports" +url="https://pypi.python.org/pypi/nosexcover/" +arch="noarch" +license="MIT" +depends="" +checkdepends="py-nose" +makedepends="python2-dev python3-dev py-setuptools" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="$pkgname-$pkgver.tar.gz::https://github.com/cmheisel/$_pkgname/archive/v$pkgver.tar.gz" +builddir="$srcdir/"$_pkgname-$pkgver + +build() { + cd "$builddir" + python2 setup.py build + python3 setup.py build +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + replaces="$pkgname" + depends="${depends//py-/py2-}" + _py python2 +} + +_py3() { + depends="${depends//py-/py3-}" + _py python3 +} + +_py() { + local python="$1" + pkgdesc="$pkgdesc (for $python)" + depends="$depends $python" + install_if="$pkgname=$pkgver-r$pkgrel $python" + + cd "$builddir" + $python setup.py install --prefix=/usr --root="$subpkgdir" +} + +check() { + cd "$builddir" + nosetests -v nosexcover/tests.py +} +sha512sums="e606e89b75d51c728d1487200f4a38afe1af93defabe6bd847b80d597374e7bb10abc2e5c8e6778bbd4f17ba8b8d7a601864a8277cd14437ee94a9e04996cf22 py-nosexcover-1.0.11.tar.gz" |