Since 1:7.0+dfsg-3, binfmt.d from systemd is used as preferred
alternative to binfmt-support. And systemd does not provide an official
way to trigger binfmt (de)registration besides a reboot.
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1012163
Since we also have binfmt-support installed, systemd and binfmt-support
work in parallel so this test becomes flaky and sometimes removing the
qemu packages would have the desired effect and sometimes not.
To make the test deterministic again, we explicitly disable emulation by
writing a 0 to /proc/sys/fs/binfmt_misc/qemu-aarch64
- multiple individual shell scripts instead of one 3.5k line monster
- tests driven by Python script allowing:
* declarative test description in coverage.txt
* collecting errors instead of aborting on first error
* skipping tests
* running specific tests