Bug#809442: autopkgtest: Add a way to run the same test script in multiple environments

Raphaël Hertzog hertzog at debian.org
Wed Dec 30 18:33:22 UTC 2015


Package: autopkgtest
Version: 3.19
Severity: wishlist

I just added some DEP-8 tests to python-django and it would have been nice
if I could have reused the same script in multiple environments (python2
only, python3 only). Right now I created symlinks to the same script
and the sole purpose of the symlink is to provide a different identifier
for autopkgtest.

I would suggest to be able to append something "@variant" like to
test names. It would keep that suffix to identify the test but it would
strip it to find the test script to actually run. The suffix would
be passed in ADT_VARIANT so that the script can make use of it if needed
(usually to set some different default values).

Here's how it could look like:

    Tests: django-admin at python2
    Depends: python-django

    Tests: django-admin at python3
    Depends: python3-django

In the mean time I opted to create "debian/tests/django-admin-py3" as a
symlink to "debian/tests/django-admin". And the script does a check based
on its name ($0) to know which variant is being run...

-- System Information:
Debian Release: stretch/sid
  APT prefers squeeze-lts
  APT policy: (500, 'squeeze-lts'), (500, 'oldoldstable'), (500, 'unstable'), (500, 'testing'), (500, 'stable'), (500, 'oldstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.3.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=fr_FR.utf8, LC_CTYPE=fr_FR.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages autopkgtest depends on:
ii  apt-utils       1.1.10
ii  libdpkg-perl    1.18.4
ii  procps          2:3.3.10-4+b1
ii  python3         3.4.3-7
ii  python3-debian  0.1.27

Versions of packages autopkgtest recommends:
ii  autodep8  0.3

Versions of packages autopkgtest suggests:
pn  lxc          <none>
pn  lxd-client   <none>
ii  qemu-system  1:2.5+dfsg-1
ii  qemu-utils   1:2.5+dfsg-1
ii  schroot      1.6.10-2

-- no debconf information



More information about the autopkgtest-devel mailing list