summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorjmcb2022-10-17 23:04:17 +0100
committerjmcb2022-10-17 23:04:17 +0100
commit702f901fb83da1028b9a49f405c098dd7012b9ea (patch)
tree6373113a6736aeb70178937774e60981fb348a39
parentda79f64d2e9f2c1c0dc4345eb404e643a4de0a66 (diff)
downloadaur-702f901fb83da1028b9a49f405c098dd7012b9ea.tar.gz
Add check()
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD7
2 files changed, 9 insertions, 1 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 6048cad2f206..2f58f8fe7951 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -5,6 +5,9 @@ pkgbase = twitch-python
url = https://github.com/PetterKraabol/Twitch-Python
arch = any
license = MIT
+ checkdepends = python-pytest
+ checkdepends = python-pytest-cov
+ checkdepends = python-responses
makedepends = python-setuptools
depends = python
depends = python-requests
diff --git a/PKGBUILD b/PKGBUILD
index a4f372b15629..617fd43e9909 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -10,7 +10,7 @@ license=('MIT')
depends=('python'
'python-requests' 'python-rx')
makedepends=('python-setuptools')
-checkdepends=()
+checkdepends=('python-pytest' 'python-pytest-cov' 'python-responses')
optdepends=()
provides=()
conflicts=()
@@ -23,6 +23,11 @@ build() {
python setup.py build
}
+check() {
+ cd "$_name-$pkgver"
+ pytest
+}
+
package() {
cd "$_name-$pkgver"
python setup.py install --root="$pkgdir" --optimize=1