]> code.ossystems Code Review - openembedded-core.git/commitdiff
oeqa/runtime/syslog: test_syslog_logger Don't try to use logread when systemd is...
authorAníbal Limón <anibal.limon@linux.intel.com>
Wed, 27 Jul 2016 22:40:41 +0000 (17:40 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 1 Aug 2016 10:46:37 +0000 (11:46 +0100)
Busybox logread uses shmmem circular buffer to retrive [1] syslog messages
when systemd is enabled this shmem circular buffer isn't enabled because
systemd journald doesn't provide it.

[1] https://git.busybox.net/busybox/tree/sysklogd/logread.c?id=accd9eeb719916da974584b33b1aeced5f3bb346#n121

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/lib/oeqa/runtime/syslog.py

index 202a63f2af997e69314de984438e1505571a4282..cce3c221d697bb3d42523da8861569b34fb64412 100644 (file)
@@ -22,7 +22,7 @@ class SyslogTestConfig(oeRuntimeTest):
         self.assertEqual(status, 0, msg="Can't log into syslog. Output: %s " % output)
 
         (status, output) = self.target.run('grep foobar /var/log/messages')
-        if status != 0:
+        if status != 0 and not oeRuntimeTest.tc.d.getVar("VIRTUAL-RUNTIME_init_manager", "") == "systemd":
             (status, output) = self.target.run('logread | grep foobar')
         self.assertEqual(status, 0, msg="Test log string not found in /var/log/messages or logread. Output: %s " % output)