[med-svn] [Git][med-team/tree-puzzle][master] 2 commits: Adds the autopackagetest (Bug #909717)

Andreas Tille gitlab at salsa.debian.org
Wed Apr 17 09:04:47 BST 2019



Andreas Tille pushed to branch master at Debian Med / tree-puzzle


Commits:
b236e84c by Camila de Moura at 2019-04-17T08:04:39Z
Adds the autopackagetest (Bug #909717)

This patch adds the autotestpackage for this package.
It looks for the documentation as also check if the command
'puzzle' is avaliable in the system.

- - - - -
b25e6a80 by Andreas Tille at 2019-04-17T08:04:43Z
Merge branch '909717' into 'master'

Adds the autopkgtest (Bug #909717)

See merge request med-team/tree-puzzle!1
- - - - -


3 changed files:

- + debian/README.test
- + debian/tests/control
- + debian/tests/run-unit-test


Changes:

=====================================
debian/README.test
=====================================
@@ -0,0 +1,8 @@
+Notes on how this package can be tested.
+────────────────────────────────────────
+
+This package can be tested by running the provided test:
+
+    sh run-unit-test
+
+in order to confirm its integrity


=====================================
debian/tests/control
=====================================
@@ -0,0 +1,7 @@
+Tests: run-unit-test 
+Depends: libc6,
+        libsprng2
+Recommends: tree-puzzle-doc
+Suggests: phylip,
+        treetool
+Restritions: allow-stderr
\ No newline at end of file


=====================================
debian/tests/run-unit-test
=====================================
@@ -0,0 +1,25 @@
+#!/bin/bash
+set -e
+
+pkg=tree-puzzle
+
+if [ "${AUTOPKGTEST_TMP}" = "" ] ; then
+    AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
+    # Double quote below to expand the temporary directory variable now versus
+    # later is on purpose.
+    # shellcheck disable=SC2064
+    trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM
+fi
+
+cp -a /usr/share/doc/${pkg}/examples/* "${AUTOPKGTEST_TMP}"
+
+cd "${AUTOPKGTEST_TMP}"
+
+#do_stuff_to_test_package#
+
+# tree-puzzle intallation check
+if hash puzzle 2>/dev/null; then
+    echo Success
+else
+    echo Fail
+fi



View it on GitLab: https://salsa.debian.org/med-team/tree-puzzle/compare/bd5c943dfe24411fcd7589cbfce1b47aaf844f65...b25e6a80bea8793cbc1aa5e21665dc36ed88ed3b

-- 
View it on GitLab: https://salsa.debian.org/med-team/tree-puzzle/compare/bd5c943dfe24411fcd7589cbfce1b47aaf844f65...b25e6a80bea8793cbc1aa5e21665dc36ed88ed3b
You're receiving this email because of your account on salsa.debian.org.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20190417/e5f43cee/attachment-0001.html>


More information about the debian-med-commit mailing list