Commit c6400def authored by Thomas Goirand's avatar Thomas Goirand

* Added Python 3.x support.

  * The python{3,}-testrepository are now providing the /usr/bin/testr
    executable, which is installed using update-alternatives.
  * Going back to using dh_python{2,3} instead of pybuild (Tristan: if you know
    how to do what I'm doing with pybuild, let me know...).
parent 141e3b43
testrepository (0.0.18-3) unstable; urgency=medium
* Added VCS fields.
* Added Python 3.x support.
* The python{3,}-testrepository are now providing the /usr/bin/testr
executable, which is installed using update-alternatives.
* Going back to using dh_python{2,3} instead of pybuild (Tristan: if you know
how to do what I'm doing with pybuild, let me know...).
* Reactivated the test suite.
-- Thomas Goirand <zigo@debian.org> Fri, 21 Mar 2014 22:44:51 +0800
......
......@@ -6,26 +6,28 @@ Uploaders: Robert Collins <robertc@robertcollins.net>,
Section: python
Priority: optional
Build-Depends: debhelper (>= 9),
dh-python,
python-all (>= 2.6.6-3~),
python-fixtures,
python-setuptools,
python-subunit,
python-testresources,
python-testscenarios,
python-testtools
python-testtools,
python3-all (>= 3.2),
python3-fixtures,
python3-setuptools,
python3-subunit,
python3-testresources,
python3-testscenarios,
python3-testtools,
subunit
Standards-Version: 3.9.5
Vcs-Svn: svn://anonscm.debian.org/python-apps/packages/testrepository/trunk/
Vcs-Browser: http://anonscm.debian.org/viewvc/python-apps/packages/testrepository/trunk/
Homepage: https://pypi.python.org/pypi/testrepository
Package: testrepository
Architecture: all
Depends: python-testrepository (>= ${source:Version}),
${misc:Depends},
${python:Depends}
Provides: ${python:Provides}
Description: Test result manager
Depends: python-testrepository (>= ${source:Version}), python3-testrepository (>= ${source:Version}), ${misc:Depends}
Description: unit test system with database of test results - metapackage and doc
Testrepository provides a database of test results and supports easy workflows
to be built on top of that database. For instance, running just failing tests
or getting the last test run back to examine again (without running the tests
......@@ -33,13 +35,14 @@ Description: Test result manager
subunit. This includes any TAP test suite and any pyunit compatible test
suite.
.
The testrepository package contains the CLI front end.
This package is a metapackage that depends on both Python 2 and 3 packages. It
also contains the documentation.
Package: python-testrepository
Architecture: all
Depends: python-subunit, ${misc:Depends}, ${python:Depends}
Provides: ${python:Provides}
Description: Database of test results - python library
Description: Database of test results - Python 2.x library
Testrepository provides a database of test results and supports easy workflows
to be built on top of that database. For instance, running just failing tests
or getting the last test run back to examine again (without running the tests
......@@ -48,4 +51,21 @@ Description: Database of test results - python library
suite.
.
The python-testrepository package contains the Python testrepository
library, which can be used for programmatic access to the database.
library for Python 2.x, which can be used for programmatic access to the
database.
Package: python3-testrepository
Architecture: all
Depends: python3-subunit, ${misc:Depends}, ${python3:Depends}
Provides: ${python3:Provides}
Description: Database of test results - Python 3.x library
Testrepository provides a database of test results and supports easy workflows
to be built on top of that database. For instance, running just failing tests
or getting the last test run back to examine again (without running the tests
again). Testrepository is compatible with any test suite that can output
subunit. This includes any TAP test suite and any pyunit compatible test
suite.
.
The python3-testrepository package contains the Python testrepository
library for Python 3.x, which can be used for programmatic access to the
database.
#!/bin/sh
set -e
if [ "$1" = "configure" ] ; then
update-alternatives --install /usr/bin/testr testr /usr/bin/testr-python2 300
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "remove" ] || [ "$1" = "disappear" ]; then
update-alternatives --remove testr /usr/bin/testr-python2
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "${1}" = "upgrade" ] ; then
if [ ! -h /usr/bin/testr ] && [ -e /usr/bin/testr ] ; then
rm /usr/bin/testr
fi
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "remove" ] ; then
update-alternatives --remove testr /usr/bin/testr-python2
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "configure" ] ; then
update-alternatives --install /usr/bin/testr testr /usr/bin/testr-python3 200
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "remove" ] || [ "$1" = "disappear" ]; then
update-alternatives --remove testr /usr/bin/testr-python3
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "${1}" = "upgrade" ] ; then
if [ ! -h /usr/bin/testr ] && [ -e /usr/bin/testr ] ; then
rm /usr/bin/testr
fi
fi
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "remove" ] ; then
update-alternatives --remove testr /usr/bin/testr-python3
fi
#DEBHELPER#
exit 0
#!/usr/bin/make -f
PYTHONS:=$(shell pyversions -vr)
PYTHON3S:=$(shell py3versions -vr)
%:
dh $@ --with python2 --buildsystem=pybuild
dh $@ --with python2,python3 --buildsystem=python_distutils
override_dh_auto_test:
echo "Test suite disabled."
./testr init
set -e && for i in $(PYTHONS) $(PYTHON3S) ; do \
TEMP_REZ=`mktemp -t` && \
echo "===> Testing with Python $$i" ; \
PYTHON=python$$i ./testr run --parallel --subunit | tee $$TEMP_REZ | subunit2pyunit ; \
cat $$TEMP_REZ | subunit-filter -s --no-passthrough | subunit-stats || true ; \
rm -f $$TEMP_REZ ; \
done
./testr slowest
override_dh_installchangelogs:
dh_installchangelogs -k NEWS
override_dh_auto_install:
set -e && for pyvers in $(PYTHONS); do \
python$$pyvers setup.py install --install-layout=deb \
--root $(CURDIR)/debian/python-testrepository; \
done
mv $(CURDIR)/debian/python-testrepository/usr/bin/testr \
$(CURDIR)/debian/python-testrepository/usr/bin/testr-python2 \
set -e && for pyvers in $(PYTHON3S); do \
python$$pyvers setup.py install --install-layout=deb \
--root $(CURDIR)/debian/python3-testrepository; \
done
mv $(CURDIR)/debian/python3-testrepository/usr/bin/testr \
$(CURDIR)/debian/python3-testrepository/usr/bin/testr-python3
override_dh_clean:
dh_clean -O--buildsystem=python_distutils
rm -rf build .testrepository Makefile dist
# Commands not to run
override_dh_installcatalogs:
override_dh_installemacsen override_dh_installifupdown:
override_dh_installinfo override_dh_installmenu override_dh_installmime:
override_dh_installmodules override_dh_installlogcheck:
override_dh_installpam override_dh_installppp override_dh_installudev:
override_dh_installwm:
override_dh_installxfonts override_dh_gconf override_dh_icons:
override_dh_usrlocal:
extend-diff-ignore = "^[^/]*[.]egg-info/"
extend-diff-ignore = "^Makefile"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment