Testsuite-Restrictions field is hard to use

Ian Jackson ijackson at chiark.greenend.org.uk
Fri Jan 27 15:58:28 UTC 2017

Package: dpkg-dev
Version: 1.18.19

>From the patch from Iain Lane:

 +This field declares the comma-separated union of all test restrictions
 +(\fBRestrictions\fP fields in \fIdebian/tests/control\fP file).

This is quite awkward to use correctly, and is a hazard to correct
implementation.  For example, dgit's debian/tests/control contains
several tests marked with Dgit-specific Restrictions with
x-dgit-... names.  The result is that with 1.18.10ubuntu1, we would
see this in dgit's .dsc:

 Testsuite-Restrictions: x-dgit-intree-only x-dgit-git-only x-dgit-schroot-build

If not interpreted very carefully, this would give a test suite runner
the erroneous impression that none of the tests can be run.

Also, Iain's stated use case in #847926 does not require anything new
in the .dsc and hence Sources.gz.  All that is required to get the
full information (debian/tests/control) is to extract the source
package.  That extraction of the source package has to be done anyway
no matter how the tests will be run.

If we do need more information in Sources.gz then maybe the set of
combinations of restrictions ought to be listed.  But then the
features might be useful too.

I'm sorry that I'm reporting this bug now, due to happening to see the
message on debian-dpkg.  But really I think:

 * Changes to the .dsc format and hence to the Sources format should
   be discussed more widely than a bug on debian-dpkg.

 * Changes to the handling of autopkgtest (DEP-8) metadata should be
   discussed on autopkgtest-devel (or other DEP-8 related places).


Ian Jackson <ijackson at chiark.greenend.org.uk>   These opinions are my own.

If I emailed you from an address @fyvzl.net or @evade.org.uk, that is
a private address which bypasses my fierce spamfilter.

More information about the autopkgtest-devel mailing list