diff options
| -rw-r--r-- | meta/lib/oeqa/runtime/cases/oe_syslog.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/meta/lib/oeqa/runtime/cases/oe_syslog.py b/meta/lib/oeqa/runtime/cases/oe_syslog.py index f3c2bedbaf..150b70d9f0 100644 --- a/meta/lib/oeqa/runtime/cases/oe_syslog.py +++ b/meta/lib/oeqa/runtime/cases/oe_syslog.py | |||
| @@ -121,11 +121,16 @@ class SyslogTestConfig(OERuntimeTestCase): | |||
| 121 | 121 | ||
| 122 | self.test_syslog_restart() | 122 | self.test_syslog_restart() |
| 123 | 123 | ||
| 124 | cmd = 'logger foobar && grep foobar /var/log/test' | 124 | cmd = 'logger foobar' |
| 125 | status,output = self.target.run(cmd) | 125 | status, output = self.target.run(cmd) |
| 126 | msg = 'Test log string not found. Output: %s ' % output | 126 | msg = 'Logger command failed, %s. Output: %s ' % (status, output) |
| 127 | self.assertEqual(status, 0, msg=msg) | 127 | self.assertEqual(status, 0, msg=msg) |
| 128 | 128 | ||
| 129 | cmd = 'cat /var/log/test' | ||
| 130 | status, output = self.target.run(cmd) | ||
| 131 | if "foobar" not in output or status: | ||
| 132 | self.fail("'foobar' not found in logfile, status %s, contents %s" % (status, output)) | ||
| 133 | |||
| 129 | cmd = "sed -i 's#LOGFILE=/var/log/test##' /etc/syslog-startup.conf" | 134 | cmd = "sed -i 's#LOGFILE=/var/log/test##' /etc/syslog-startup.conf" |
| 130 | self.target.run(cmd) | 135 | self.target.run(cmd) |
| 131 | self.test_syslog_restart() | 136 | self.test_syslog_restart() |
