Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #15137

Re: Package testing with Salsa CI for new packages

From Andrey Rakhmatullin <wrar@wrar.name>
Newsgroups linux.debian.maint.python
Subject Re: Package testing with Salsa CI for new packages
Date 2023-08-18 19:50 +0200
Message-ID <H4bLH-2LOR-1@gated-at.bofh.it> (permalink)
References <H3MWZ-2whZ-9@gated-at.bofh.it> <H4awh-2L8W-5@gated-at.bofh.it> <H4biG-2LEJ-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Aug 18, 2023 at 07:19:18PM +0200, Paul Boddie wrote:
> > > Here, it would seem that the most prudent approach is to use the Salsa CI
> > > service instead of trying to get the test suite to run during the package
> > > build process.
> > 
> > You should do both if possible, assuming that by "Salsa CI service" you
> > mean autopkgtests which you can, and IMO should, also run locally.
> 
> I'm not really clear on what autopkgtest really is, other than a tool that 
> uses some kind of test suite description that may reside in debian/test. I'm 
> also not completely clear on what is supposed to invoke it, other than either 
> the Salsa CI mechanism or dh_auto_test.
The maintainer is supposed to invoke it before uploading the package, and
the Debian infra invokes it on all packages that are uploaded.
Notably, dh_auto_test is unrelated.

> In the Debian Wiki documentation...
> 
> https://wiki.debian.org/Python/LibraryStyleGuide
> 
> ...it mentions a field in debian/control:
> 
> Testsuite: autopkgtest-pkg-python
> 
> My impression is that this calls autodep8 to generate some kind of test suite 
Yes.
Though note that it generates a trivial test that only checks a top-level
import (just like the wiki page says).

> description which is then invoked by dh_auto_test.
It's not invoked by dh_auto_test. autopkgtests are not a part of the
package build process and they operate on built binary packages.

> It doesn't help that there 
> is an alternative to this that resembles it but behaves differently:
> 
> Testsuite: autopkgtest-pkg-pybuild
It just generates a different (better) test.

> > > I have also found it difficult to persuade the tests to run successfully
> > > during the build process. A few of these attempt to invoke the moin
> > > program, but this cannot be located since it is not installed in the
> > > build environment.
> >
> > This should also be fine, unless it's completely impossible to run it
> > without installing into /.
> 
> The moin program is made available in setup.py using an entry point. Maybe if 
> there were some kind of script instead, it would work.
AFAIK there should be ways to work with this.
Ideally, of course, the upstream test suite should support this, but I
understand that not all upstreams use common practices.

> > > However, one conclusion is that testing a system, as some of the
> > > test cases appear to do, and as opposed to testing library functionality,
> > > is not necessarily appropriate when directed by something like
> > > dh_auto_test.
> >
> > If there are tests that can't be run at build time you can skip those. You
> > can even ask the upstream to provide tool arguments to simplify that.
> 
> I may well discuss such matters with them. One challenge that is relevant in 
> this situation is that upstream have been working in their own virtualenv (or 
> venv, or whatever it is now) world for a few years, using plenty of 
> dependencies that were not packaged in Debian. 
Which is by itself not a problem from the technical side, as you could
just package those (I understand that this requires effort and may have
other problems, but by itself it's normal).

Back to linux.debian.maint.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-17 17:20 +0200
  Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-18 10:00 +0200
    Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-18 13:20 +0200
      Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-18 16:20 +0200
        Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-18 19:10 +0200
          Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-18 20:00 +0200
            Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-19 19:10 +0200
              Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-19 20:40 +0200
                Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-20 00:50 +0200
                Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-20 14:10 +0200
                Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-20 23:20 +0200
                Re: Package testing with Salsa CI for new packages Carles Pina i Estany <carles@pina.cat> - 2023-08-21 15:10 +0200
                Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-21 19:20 +0200
  Re: Package testing with Salsa CI for new packages Andrey Rakhmatullin <wrar@wrar.name> - 2023-08-18 18:30 +0200
    Re: Package testing with Salsa CI for new packages Paul Boddie <paul@boddie.org.uk> - 2023-08-18 19:20 +0200
      Re: Package testing with Salsa CI for new packages Andrey Rakhmatullin <wrar@wrar.name> - 2023-08-18 19:50 +0200

csiph-web