aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmish2020-03-09 11:36:23 +0530
committerAmish2020-03-09 11:36:23 +0530
commit806f8ecf3e5ad93e91c91b368a1a511245dd422c (patch)
tree2dd7ecf484c61a6380e6e91ac295053c0af4d496
parent81caef70d8e01ffc6e0013673e9a981f9bc59e49 (diff)
downloadaur-806f8ecf3e5ad93e91c91b368a1a511245dd422c.tar.gz
make tests use directory inside srcdir
-rw-r--r--PKGBUILD8
1 files changed, 5 insertions, 3 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 912dcced900b..9b8aabf9f2e7 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -32,10 +32,12 @@ build() {
check() {
cd $_name-$pkgver
- mkdir -p /tmp/fangfrisch/unittest
- sqlite3 /tmp/fangfrisch/unittest/db.sqlite < tests/tests.sql
+ rm -rf tmp_unittest
+ mkdir -p tmp_unittest
+ sed -i -e "s,/tmp/fangfrisch/unittest,$srcdir/$_name-$pkgver/tmp_unittest," tests/tests.conf tests/__init__.py
+ sqlite3 tmp_unittest/db.sqlite < tests/tests.sql
python -m unittest discover tests/
- rm -rf /tmp/fangfrisch
+ rm -rf tmp_unittest
}
package() {