Package: clamav
Version: 0.97.8+dfsg-1ubuntu1.13.04.1
Severity: wishlist
Tags: patch
User: yolanda.ro...@canonical.com
Usertags: origin-ubuntu saucy ubuntu-patch

debian/tests: added autopkgtests


-- System Information:
Debian Release: wheezy/sid
  APT prefers saucy-updates
  APT policy: (500, 'saucy-updates'), (500, 'saucy-security'), (500, 'saucy')
Architecture: amd64 (x86_64)

Kernel: Linux 3.8.0-14-generic (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

-- no debconf information
diff -u clamav-0.97.8+dfsg/debian/changelog clamav-0.97.8+dfsg/debian/changelog
--- clamav-0.97.8+dfsg/debian/changelog
+++ clamav-0.97.8+dfsg/debian/changelog
@@ -1,3 +1,15 @@
+clamav (0.97.8+dfsg-1ubuntu3) saucy; urgency=low
+
+  * debian/tests: updated clamd test to don't required network access
+
+ -- Yolanda Robla <yolanda.ro...@canonical.com>  Wed, 29 May 2013 10:41:31 +0200
+
+clamav (0.97.8+dfsg-1ubuntu2) saucy; urgency=low
+
+  * debian/tests: Add autopkgtest.
+
+ -- Yolanda Robla <yolanda.ro...@canonical.com>  Wed, 22 May 2013 12:29:44 +0200
+
 clamav (0.97.8+dfsg-1ubuntu1.13.04.1) raring-security; urgency=low
 
   [ Seth Arnold ]
diff -u clamav-0.97.8+dfsg/debian/control clamav-0.97.8+dfsg/debian/control
--- clamav-0.97.8+dfsg/debian/control
+++ clamav-0.97.8+dfsg/debian/control
@@ -9,6 +9,7 @@
 Vcs-Git: git://git.debian.org/pkg-clamav/clamav.git
 Vcs-Browser: http://git.debian.org/?p=pkg-clamav/clamav.git;a=summary
 Homepage: http://www.clamav.net/
+XS-Testsuite: autopkgtest
 
 Package: clamav-base
 Architecture: all
only in patch2:
unchanged:
--- clamav-0.97.8+dfsg.orig/debian/tests/control
+++ clamav-0.97.8+dfsg/debian/tests/control
@@ -0,0 +1,3 @@
+Tests: clamd client milter
+Depends: clamav-daemon, clamav, clamav-milter
+Restrictions: needs-root
only in patch2:
unchanged:
--- clamav-0.97.8+dfsg.orig/debian/tests/client
+++ clamav-0.97.8+dfsg/debian/tests/client
@@ -0,0 +1,13 @@
+#!/bin/bash
+#---------------
+# Testing client
+#---------------
+set -e
+ADMIN=clamscan
+$ADMIN --help > /dev/null 2>&1
+RET=$?
+
+if [[ $RET != 0 ]]; then
+  echo "ERROR, ${ADMIN} is not running"
+  exit $RET
+fi
only in patch2:
unchanged:
--- clamav-0.97.8+dfsg.orig/debian/tests/milter
+++ clamav-0.97.8+dfsg/debian/tests/milter
@@ -0,0 +1,13 @@
+#!/bin/bash
+#----------------------
+# Testing clamav-milter
+#----------------------
+set -e
+DAEMON=clamav-milter
+
+if pidof -x $DAEMON > /dev/null; then
+    echo "OK"
+else
+    echo "ERROR: ${DAEMON} IS NOT RUNNING"
+    exit 1
+fi
only in patch2:
unchanged:
--- clamav-0.97.8+dfsg.orig/debian/tests/clamd
+++ clamav-0.97.8+dfsg/debian/tests/clamd
@@ -0,0 +1,20 @@
+#!/bin/bash
+#----------------------
+# Testing clamav-daemon
+#----------------------
+set -e
+DAEMON=clamd
+
+# copy the file form unit tests to clamav directory
+cp `dirname $0`/../../unit_tests/input/bytecode.cvd /var/lib/clamav/main.cvd > /dev/null 2>&1
+cp `dirname $0`/../../unit_tests/input/bytecode.cvd /var/lib/clamav/daily.cvd > /dev/null 2>&1
+
+# restart clamav
+/etc/init.d/clamav-daemon start > /dev/null 2>&1
+
+if pidof -x $DAEMON > /dev/null; then
+    echo "OK"
+else
+    echo "ERROR: ${DAEMON} IS NOT RUNNING"
+    exit 1
+fi

Reply via email to