[r-cran-matchit] 02/03: Add autopkgtest

Andreas Tille tille at debian.org
Fri Oct 20 06:29:58 UTC 2017


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch master
in repository r-cran-matchit.

commit 5e7890e27ede4d88280f8de30d2f98c1231c4ac8
Author: Andreas Tille <tille at debian.org>
Date:   Fri Oct 20 08:24:47 2017 +0200

    Add autopkgtest
---
 debian/changelog           |  1 +
 debian/docs                |  2 ++
 debian/tests/control       |  5 +++++
 debian/tests/run-unit-test | 17 +++++++++++++++++
 4 files changed, 25 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index a3de2f8..b54da13 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -11,6 +11,7 @@ r-cran-matchit (3.0.1-1) UNRELEASED; urgency=medium
   * Secure URI in watch file
   * Rename source package to r-cran-matchit
   * Canonical homepage for CRAN packages
+  * Add autopkgtest
 
  -- Andreas Tille <tille at debian.org>  Fri, 20 Oct 2017 07:58:43 +0200
 
diff --git a/debian/docs b/debian/docs
new file mode 100644
index 0000000..67ce40b
--- /dev/null
+++ b/debian/docs
@@ -0,0 +1,2 @@
+debian/tests/run-unit-test
+tests
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..a62fb6e
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,5 @@
+Tests: run-unit-test
+Depends: @, r-cran-testthat,
+Restrictions: allow-stderr
+
+
diff --git a/debian/tests/run-unit-test b/debian/tests/run-unit-test
new file mode 100644
index 0000000..8810a0b
--- /dev/null
+++ b/debian/tests/run-unit-test
@@ -0,0 +1,17 @@
+#!/bin/sh -e
+
+pkgname=MatchIt
+debname=r-cran-matchit
+
+if [ "$ADTTMP" = "" ] ; then
+    ADTTMP=`mktemp -d /tmp/${debname}-test.XXXXXX`
+    trap "rm -rf $ADTTMP" 0 INT QUIT ABRT PIPE TERM
+fi
+cd $ADTTMP
+cp -a /usr/share/doc/$debname/tests/* $ADTTMP
+gunzip -r *
+for testfile in *.R; do
+    echo "BEGIN TEST $testfile"
+    LC_ALL=C R --no-save < $testfile
+done
+

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/r-cran-matchit.git



More information about the debian-science-commits mailing list