Re: [deb-ci] testing sysvinit scripts when both sysvinit and systemd supported by package
Le 13 juin 2017 12:36:49 GMT+02:00, Ansgar Burchardt a écrit : >Hi, > >On Tue, 2017-06-13 at 09:13 +0200, p...@reseau-libre.net wrote: >> I'm writting deb-ci tests to check backward support to sysvinit for >> openscap-daemon. I've written a sysvinit script, the systemd service >> file also exists [1]. >> >> The problem is that the deb-ci test (which run explicitly >> /etc/init.d/openscap-daemon) fails because adt-run create a testbed >> with >> systemd installed, even if i specified a test-dependency on sysv-rc, >> sysv-rc-conf, sysvinit-core, sysvinit-utils. > >Just installing sysvinit-core doesn't make sysvinit the active init >system: you need to reboot. > >I think the boot-smoke test in the systemd source package does that. >At least it claims to check that rebooting 20 times works. The >autopkgtest documentation also mentions "needs-reboot". > >Ansgar Thank's a lot Ansgar ! It works perfectly ! The boot-smoke script you pointed is a very good example of such a usage. -- Philippe.
Re: [deb-ci] testing sysvinit scripts when both sysvinit and systemd supported by package
Hi, On Tue, 2017-06-13 at 09:13 +0200, p...@reseau-libre.net wrote: > I'm writting deb-ci tests to check backward support to sysvinit for > openscap-daemon. I've written a sysvinit script, the systemd service > file also exists [1]. > > The problem is that the deb-ci test (which run explicitly > /etc/init.d/openscap-daemon) fails because adt-run create a testbed > with > systemd installed, even if i specified a test-dependency on sysv-rc, > sysv-rc-conf, sysvinit-core, sysvinit-utils. Just installing sysvinit-core doesn't make sysvinit the active init system: you need to reboot. I think the boot-smoke test in the systemd source package does that. At least it claims to check that rebooting 20 times works. The autopkgtest documentation also mentions "needs-reboot". Ansgar
[deb-ci] testing sysvinit scripts when both sysvinit and systemd supported by package
Hello ! I'm writting deb-ci tests to check backward support to sysvinit for openscap-daemon. I've written a sysvinit script, the systemd service file also exists [1]. The problem is that the deb-ci test (which run explicitly /etc/init.d/openscap-daemon) fails because adt-run create a testbed with systemd installed, even if i specified a test-dependency on sysv-rc, sysv-rc-conf, sysvinit-core, sysvinit-utils. The package then install the service file and not the sysvinit file, making the test fail [2][3] Do you know the way to test properly sysvinit scripts using deb-ci ? Thanks ! [1] https://anonscm.debian.org/cgit/pkg-security/openscap-daemon.git/tree/debian/openscap-daemon.init [2] https://ci.debian.net/packages/o/openscap-daemon/unstable/amd64/ [3] https://ci.debian.net/data/autopkgtest/unstable/amd64/o/openscap-daemon/20170613_032717/log.gz -- Philippe.