From: Ross Burton Date: Thu, 5 Dec 2013 12:56:01 +0000 (+0000) Subject: lib/oeqa/runtime: output more logging from systemd when services have failed X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~35205 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=e371765431be25b81dbdb385233e3db5851e59d0;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git lib/oeqa/runtime: output more logging from systemd when services have failed If some services have failed to start, get the status of them and some of their log to help debug the problem. Signed-off-by: Ross Burton Signed-off-by: Richard Purdie --- diff --git a/meta/lib/oeqa/runtime/systemd.py b/meta/lib/oeqa/runtime/systemd.py index e4f433632f7..17cc19f7a51 100644 --- a/meta/lib/oeqa/runtime/systemd.py +++ b/meta/lib/oeqa/runtime/systemd.py @@ -21,7 +21,9 @@ class SystemdTests(oeRuntimeTest): @skipUnlessPassed('test_systemd_version') def test_systemd_failed(self): (status, output) = self.target.run('systemctl --failed | grep "0 loaded units listed"') - self.assertEqual(status, 0, msg="Failed systemd services: %s" % self.target.run('systemctl --failed')[1]) + if status != 0: + print self.target.run('systemctl status --failed -l')[1] + self.fail("Some systemd units failed.") @skipUnlessPassed('test_systemd_version') def test_systemd_service(self):