[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

dpkg-source to automatically add a Testsuite field



Hi!

On Tue, 2014-07-08 at 11:22:57 -0300, Antonio Terceiro wrote:
> On Tue, Jul 08, 2014 at 03:06:14AM +0200, Guillem Jover wrote:
> > > How will it handle an existing value in that field? In the future, we
> > > might have other forms of test suite, thus requiring different items in
> > > the Testsuite: field.  What happens when there is already
> > > 
> > >   Testsuite: foo
> > > 
> > > and dpkg-source detects the presence of debian/tests/control? Will it
> > > merge `autopkgtest` into the list, or will it replace the existing
> > > value?
> > 
> > Ah indeed, here's the current behavior:
> > 
> > The field is parsed as a comma-separated list of values (as per the
> > spec). If the debian/tests/control file is present then the value will
> > be added to the list. The values will always get emitted in alphabetical
> > order as a comma-separated list, any dupes squashed, so that the output
> > is reproducible. Unknown values are emitted untouched.
> > 
> > If the field contains ?autopkgtest?, but the debian/tests/control file
> > is not present, then a warning will be issued, and the value preserved,
> > as in ?the maintainer knows better!??. But maybe it is actually better
> > to warn and just trim the ?autopkgtest? value?
> > 
> > Does this resolve your concern?
> 
> Absolutely.

Good. :) At the end I went for warning and removing the autopkgtest
value if the file is missing, as that seemed to make more sense, but we
can certainly revisit that if there's advantages in keeping the value.

It migth make sense to update the last section describing the field
in ?doc/README.package-tests.rst?, now that this is handled by
dpkg-source >= 1.17.11.

Thanks,
Guillem



Reply to: