[Python-modules-commits] r21816 - in packages/python-notify2/trunk/debian (3 files)
takluyver-guest at users.alioth.debian.org
takluyver-guest at users.alioth.debian.org
Sat May 19 10:59:10 UTC 2012
Date: Saturday, May 19, 2012 @ 10:59:09
Author: takluyver-guest
Revision: 21816
Use xvfb-run to simplify running tests.
Added:
packages/python-notify2/trunk/debian/runtests.sh
Modified:
packages/python-notify2/trunk/debian/control
packages/python-notify2/trunk/debian/rules
Modified: packages/python-notify2/trunk/debian/control
===================================================================
--- packages/python-notify2/trunk/debian/control 2012-05-18 15:48:09 UTC (rev 21815)
+++ packages/python-notify2/trunk/debian/control 2012-05-19 10:59:09 UTC (rev 21816)
@@ -12,6 +12,7 @@
dbus-x11,
notification-daemon,
xvfb,
+ xauth,
python-gi,
python3-gi,
gir1.2-gdkpixbuf-2.0
Modified: packages/python-notify2/trunk/debian/rules
===================================================================
--- packages/python-notify2/trunk/debian/rules 2012-05-18 15:48:09 UTC (rev 21815)
+++ packages/python-notify2/trunk/debian/rules 2012-05-19 10:59:09 UTC (rev 21816)
@@ -4,24 +4,13 @@
PYTHON2=$(shell pyversions -vr)
PYTHON3=$(shell py3versions -vr)
-DISPLAY=:99
-DISPLAYENV=DISPLAY=$(DISPLAY)
%:
dh $@ --with python2,python3
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
-test-env:
- # Set up X server and notification daemon
- Xvfb $(DISPLAY) -ac &
- sleep 1
- $(DISPLAYENV) /usr/lib/notification-daemon/notification-daemon &
- sleep 1
-
-test-python%:
- $(DISPLAYENV) python$* test_notify2.py
-
-override_dh_auto_test: test-env $(PYTHON2:%=test-python%) $(PYTHON3:%=test-python%)
+override_dh_auto_test:
+ PYTHONS="$(PYTHON2) $(PYTHON3)" xvfb-run -a debian/runtests.sh
endif
build-python%:
Added: packages/python-notify2/trunk/debian/runtests.sh
===================================================================
--- packages/python-notify2/trunk/debian/runtests.sh (rev 0)
+++ packages/python-notify2/trunk/debian/runtests.sh 2012-05-19 10:59:09 UTC (rev 21816)
@@ -0,0 +1,12 @@
+# Runs the tests - called with xvfb-run to provide a display
+
+set -e
+# Start the notification daemon
+/usr/lib/notification-daemon/notification-daemon &
+sleep 1
+
+# Test with the requested versions of Python
+for VER in $PYTHONS
+do
+ python$VER test_notify2.py
+done
Property changes on: packages/python-notify2/trunk/debian/runtests.sh
___________________________________________________________________
Added: svn:executable
+ *
More information about the Python-modules-commits
mailing list