On Mon, May 25, 2020 at 07:35:30PM -0300, Antonio Terceiro wrote: > On Mon, May 25, 2020 at 09:22:52PM +0200, Pierre-Elliott Bécue wrote: > > Le mercredi 22 avril 2020 à 00:08:37+0900, Ryutaroh Matsumoto a écrit : > > > Package: lxc-tests > > > Version: 1:4.0.2-1~1 > > > Severity: wishlist > > > > > > Dear Maintainer, > > > > > > Only qemu-kvm is allowed as an autopkgtest backend of LXC, as > > > debian/tests/control has the following line: > > > Restrictions: needs-root allow-stderr isolation-machine > > > > > > On the other hand, debian/tests/control skips tests that cannot > > > be executed in a container as > > > > > > # Skip some tests when running in a container > > > if [ -f /run/container_type ] || (type systemd-detect-virt >/dev/null > > > 2>&1 && systemd-detect-virt --container >/dev/null 2>&1); then > > > [ "$testbin" = "/usr/bin/lxc-test-apparmor" ] && \ > > > ignore "$STRING" && continue > > > > > > [ "$testbin" = "/usr/bin/lxc-test-device-add-remove" ] && \ > > > ignore "$STRING" && continue > > > > > > [ "$testbin" = "/usr/bin/lxc-test-reboot" ] && \ > > > ignore "$STRING" && continue > > > fi > > > > > > So, please consider to allow lxc as an autopkgtest backend of lxc itself. > > > > The more tests autopkgtest runs the better. If I put isolation-container > > instead of isolation-machine, the tests would be allowed to run in > > either a VM or a container, which could mean running less tests. > > I think you have your reasoning backwards. isolation-container runs in > both containers and vms; isolation-machine runs only on vms; so > isolation-container tests runs on *more* environments, not less. > > e.g. ci.debian.net uses containers, so tests marked as isolation-machine > are skipped there.
I think I now understand your point: if you allow to run in containers, it will run less tests. what you can do is have two test declarations of the same test in the control file: one with isolation-container and another with isolation-machine (and maybe skip the one with isolation-container if running in a vm)
signature.asc
Description: PGP signature

