aboutsummaryrefslogtreecommitdiffstats
path: root/testing/zimg
diff options
context:
space:
mode:
authorprspkt <prspkt@protonmail.com>2019-08-13 21:30:03 +0300
committerprspkt <prspkt@protonmail.com>2019-08-13 21:30:13 +0300
commit7572a9337198d6d281be1409a97312b6864f0961 (patch)
tree3d235a601435edec05fbae488d9144a5aa26629d /testing/zimg
parentc1782be93d7ee2bbdc803490d6e089d9b1f6618a (diff)
downloadaports-7572a9337198d6d281be1409a97312b6864f0961.tar.bz2
aports-7572a9337198d6d281be1409a97312b6864f0961.tar.xz
testing/zimg: run test suite in the build stage
Signed-off-by: prspkt <prspkt@protonmail.com>
Diffstat (limited to 'testing/zimg')
-rw-r--r--testing/zimg/APKBUILD21
1 files changed, 11 insertions, 10 deletions
diff --git a/testing/zimg/APKBUILD b/testing/zimg/APKBUILD
index c048fab487..72f81833da 100644
--- a/testing/zimg/APKBUILD
+++ b/testing/zimg/APKBUILD
@@ -12,6 +12,7 @@ subpackages="$pkgname-doc $pkgname-dev"
source="zimg-$pkgver.tar.gz::https://github.com/sekrit-twc/zimg/archive/release-$pkgver.tar.gz
zimg-gtest-1.8.0.tar.gz::https://github.com/google/googletest/archive/release-1.8.0.tar.gz"
builddir="$srcdir/zimg-release-$pkgver"
+options="!check" # we run tests in the build stage
prepare() {
default_prepare
@@ -22,7 +23,7 @@ prepare() {
}
build() {
- # do not enable tests here, they make zimg slower
+ # build and run test binaries here
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -30,12 +31,15 @@ build() {
--sysconfdir=/etc \
--mandir=/usr/share/man \
--localstatedir=/var \
- --disable-static
+ --disable-static \
+ --enable-unit-test
make
- make -j1 DESTDIR="$pkgdir" install
-}
+ make test/unit_test.log
+ test/unit_test
-check() {
+ # build release binaries here without enabling tests,
+ # as they make zimg slower
+ make clean
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -43,15 +47,12 @@ check() {
--sysconfdir=/etc \
--mandir=/usr/share/man \
--localstatedir=/var \
- --disable-static \
- --enable-unit-test
+ --disable-static
make
- make test/unit_test.log
- test/unit_test
}
package() {
- return 0
+ make -j1 DESTDIR="$pkgdir" install
}
sha512sums="b688f8e93a2e4549f2c844cd58c6e0714e6494d6fc8c800dc1b0cdf2278fb9925a646fc332350c1b5d77cef2134bf35e18a873c24ea1979c1adce57bfef68ebe zimg-2.9.2.tar.gz