add Makefile targets for regression tests
authorDietmar Maurer <dietmar@proxmox.com>
Tue, 13 May 2014 12:18:08 +0000 (14:18 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Tue, 13 May 2014 12:18:08 +0000 (14:18 +0200)
Always run tests before assembling a Debian package.

Makefile
test/Makefile [new file with mode: 0644]

index 0f6d973..e20e0b1 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -26,7 +26,7 @@ dinstall: deb
 
 
 .PHONY: deb
-deb ${DEB}:
+deb ${DEB}: check
        rm -rf build
        rsync -a src/ build
        rsync -a debian/ build/debian
@@ -35,9 +35,14 @@ deb ${DEB}:
        cd build; dpkg-buildpackage -rfakeroot -b -us -uc
        lintian ${DEB}
 
+.PHONY: check
+check: 
+       make -C test check
+
 .PHONY: clean
 clean:         
        make -C src clean
+       make -C test clean
        rm -rf *~ debian/*~ example/*~ *.deb *.changes build ${PACKAGE}-*.tar.gz
 
 .PHONY: distclean
diff --git a/test/Makefile b/test/Makefile
new file mode 100644 (file)
index 0000000..fea9c21
--- /dev/null
@@ -0,0 +1,17 @@
+
+all:
+
+.PHONY: check
+check:
+       ./fwtester.pl
+
+.PHONY: install
+install: check
+
+.PHONY: clean
+clean:
+       rm -f *~ test-*/*~
+
+.PHONY: distclean
+distclean: clean
+