[Pkg-mpd-commits] [python-mpd] 08/19: Add autopkgtests

Simon McVittie smcv at debian.org
Sun May 22 18:17:08 UTC 2016


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

smcv pushed a commit to branch debian/experimental
in repository python-mpd.

commit d3a4438c455af86069d9e3bb308402c5fceb4aa7
Author: Simon McVittie <smcv at debian.org>
Date:   Sat Apr 30 15:11:30 2016 +0100

    Add autopkgtests
    
    The tests are not run at build-time because they require a hard-coded
    listening port.
---
 debian/changelog     |  2 ++
 debian/tests/control | 13 +++++++++++++
 debian/tests/python2 |  7 +++++++
 debian/tests/python3 |  7 +++++++
 4 files changed, 29 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index a73648e..2b6b860 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -15,6 +15,8 @@ python-mpd (0.5.5-1) UNRELEASED; urgency=medium
     - add .install files to install everything
   * Run dh_install with --fail-missing to catch mistakes
     - specifically don't install mpd_test.py, not needed
+  * Add autopkgtests. The tests are not run at build-time because they
+    require a hard-coded listening port.
 
  -- Simon McVittie <smcv at debian.org>  Sat, 30 Apr 2016 13:43:38 +0100
 
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..5483aa7
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,13 @@
+Tests: python2
+Depends:
+ python-mock,
+ python-mpd,
+Restrictions:
+ isolation-container,
+
+Tests: python3
+Depends:
+ python3-mock,
+ python3-mpd,
+Restrictions:
+ isolation-container,
diff --git a/debian/tests/python2 b/debian/tests/python2
new file mode 100755
index 0000000..7bef56c
--- /dev/null
+++ b/debian/tests/python2
@@ -0,0 +1,7 @@
+#!/bin/sh
+exec 2>&1
+set -e
+set -x
+install mpd_test.py "$ADTTMP"
+cd "$ADTTMP"
+python2 ./mpd_test.py
diff --git a/debian/tests/python3 b/debian/tests/python3
new file mode 100755
index 0000000..5192cdc
--- /dev/null
+++ b/debian/tests/python3
@@ -0,0 +1,7 @@
+#!/bin/sh
+exec 2>&1
+set -e
+set -x
+install mpd_test.py "$ADTTMP"
+cd "$ADTTMP"
+python3 ./mpd_test.py

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mpd/python-mpd.git



More information about the Pkg-mpd-commits mailing list