Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] lib/oeqa/runtime/systemd: Add a basic runtime test for the journal
@ 2015-03-11 21:25 Randy Witt
  2015-03-11 21:28 ` Randy Witt
  0 siblings, 1 reply; 3+ messages in thread
From: Randy Witt @ 2015-03-11 21:25 UTC (permalink / raw)
  To: openembedded-core

The test_systemd_journal() test will fail if journalctl exits with a
non-zero exit status. The exit status is non-zero even if there are no
journal files, which is what drove the creation of this test.

[Yocto #7388]

Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com>
---
 meta/lib/oeqa/runtime/systemd.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/meta/lib/oeqa/runtime/systemd.py b/meta/lib/oeqa/runtime/systemd.py
index 1451698..5935edd 100644
--- a/meta/lib/oeqa/runtime/systemd.py
+++ b/meta/lib/oeqa/runtime/systemd.py
@@ -86,3 +86,9 @@ class SystemdServiceTests(SystemdTest):
         self.systemctl('is-enabled', 'avahi-daemon.service', expected=1)
         self.systemctl('enable', 'avahi-daemon.service')
         self.systemctl('is-enabled', 'avahi-daemon.service')
+
+class SystemdJournalTests(SystemdTest):
+    @skipUnlessPassed('test_ssh')
+    def test_systemd_journal(self):
+        (status, output) = self.target.run('journalctl')
+        self.assertEqual(status, 0, output)
-- 
1.9.3



^ permalink raw reply related	[flat|nested] 3+ messages in thread
* [PATCH] lib/oeqa/runtime/systemd: Add a basic runtime test for the journal
@ 2015-03-09 20:04 Randy Witt
  0 siblings, 0 replies; 3+ messages in thread
From: Randy Witt @ 2015-03-09 20:04 UTC (permalink / raw)
  To: openembedded-core

The test_systemd_journal() test will fail if journalctl exits with a
non-zero exit status. The exit status is non-zero even if there are no
journal files, which is what drove the creation of this test.

[Yocto #7388]

Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com>
---
 meta/lib/oeqa/runtime/systemd.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/meta/lib/oeqa/runtime/systemd.py b/meta/lib/oeqa/runtime/systemd.py
index 1451698..5935edd 100644
--- a/meta/lib/oeqa/runtime/systemd.py
+++ b/meta/lib/oeqa/runtime/systemd.py
@@ -86,3 +86,9 @@ class SystemdServiceTests(SystemdTest):
         self.systemctl('is-enabled', 'avahi-daemon.service', expected=1)
         self.systemctl('enable', 'avahi-daemon.service')
         self.systemctl('is-enabled', 'avahi-daemon.service')
+
+class SystemdJournalTests(SystemdTest):
+    @skipUnlessPassed('test_ssh')
+    def test_systemd_journal(self):
+        (status, output) = self.target.run('journalctl')
+        self.assertEqual(status, 0, output)
-- 
1.9.3



^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-03-11 21:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-11 21:25 [PATCH] lib/oeqa/runtime/systemd: Add a basic runtime test for the journal Randy Witt
2015-03-11 21:28 ` Randy Witt
  -- strict thread matches above, loose matches on Subject: below --
2015-03-09 20:04 Randy Witt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox