Package: python-linecache2
Version: 1.0.0-1
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu wily ubuntu-patch
Dear Maintainer,
In Ubuntu, the attached patch was applied by James Hunt to run the unit
tests during build. It seems like a good idea, so I'm passing the patch
on to you. Thanks for your consideration!
-- System Information:
Debian Release: jessie/sid
APT prefers wily-updates
APT policy: (500, 'wily-updates'), (500, 'wily-security'), (500, 'wily')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.1.0-2-generic (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru python-linecache2-1.0.0/debian/control python-linecache2-1.0.0/debian/control
--- python-linecache2-1.0.0/debian/control 2015-07-08 09:25:25.000000000 -0400
+++ python-linecache2-1.0.0/debian/control 2015-08-17 13:49:57.000000000 -0400
@@ -15,6 +15,7 @@
Build-Depends-Indep: python-fixtures,
python-unittest2,
python3-fixtures,
+ python3-unittest2,
Standards-Version: 3.9.6
Vcs-Browser: http://anonscm.debian.org/gitweb/?p=openstack/python-linecache2.git
Vcs-Git: git://anonscm.debian.org/openstack/python-linecache2.git
diff -Nru python-linecache2-1.0.0/debian/rules python-linecache2-1.0.0/debian/rules
--- python-linecache2-1.0.0/debian/rules 2015-07-08 09:25:25.000000000 -0400
+++ python-linecache2-1.0.0/debian/rules 2015-08-04 06:30:22.000000000 -0400
@@ -32,6 +32,16 @@
dh_clean -O--buildsystem=python_distutils
rm -rf build
+override_dh_auto_test:
+ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
+ @echo "===> Running tests"
+ set -ex && for i in $(PYTHONS) $(PYTHON3S) ; do \
+ PYMAJOR=`echo $$i | cut -d'.' -f1` ; \
+ echo "===> Testing with python$$i (python$$PYMAJOR)" ; \
+ PYTHON=python$$i python$$PYMAJOR-unit2; \
+ done
+endif
+
# Commands not to run
override_dh_installcatalogs:
override_dh_installemacsen override_dh_installifupdown: