[OE-core] [PATCH 2/2] systemd: skip service tests on long boot times

Benjamin Esquivel benjamin.esquivel at linux.intel.com
Thu Oct 22 22:45:11 UTC 2015


arrange the runtime systemd services testing to depend upon the
checking of the boot time to be less than systemd's unit (services)
start timeout
this will prevent the service tests failing on a condition that is
well known to happen when the virtual target is choked on IO/CPU
resources

[YOCTO#8142]

Signed-off-by: Benjamin Esquivel <benjamin.esquivel at linux.intel.com>
---
 meta/lib/oeqa/runtime/systemd.py | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/meta/lib/oeqa/runtime/systemd.py b/meta/lib/oeqa/runtime/systemd.py
index 251d06e..4e0a556 100644
--- a/meta/lib/oeqa/runtime/systemd.py
+++ b/meta/lib/oeqa/runtime/systemd.py
@@ -80,7 +80,7 @@ class SystemdBasicTests(SystemdTest):
             time.sleep(10)
 
     @testcase(550)
-    @skipUnlessPassed('test_systemd_basic')
+    @skipUnlessPassed('test_systemd_boot_time')
     def test_systemd_failed(self):
         settled, output = self.settle()
         self.assertTrue(settled, msg="Timed out waiting for systemd to settle:\n" + output)
@@ -98,13 +98,13 @@ class SystemdServiceTests(SystemdTest):
         if not self.hasPackage('avahi-daemon'):
             raise unittest.SkipTest("Testcase dependency not met: need avahi-daemon installed on target")
 
-    @skipUnlessPassed('test_systemd_basic')
+    @skipUnlessPassed('test_systemd_boot_time')
     def test_systemd_status(self):
         self.check_for_avahi()
         self.systemctl('status --full', 'avahi-daemon.service')
 
     @testcase(695)
-    @skipUnlessPassed('test_systemd_status')
+    @skipUnlessPassed('test_systemd_boot_time')
     def test_systemd_stop_start(self):
         self.check_for_avahi()
         self.systemctl('stop', 'avahi-daemon.service')
@@ -113,7 +113,7 @@ class SystemdServiceTests(SystemdTest):
         self.systemctl('is-active', 'avahi-daemon.service', verbose=True)
 
     @testcase(696)
-    @skipUnlessPassed('test_systemd_basic')
+    @skipUnlessPassed('test_systemd_boot_time')
     def test_systemd_disable_enable(self):
         self.check_for_avahi()
         self.systemctl('disable', 'avahi-daemon.service')
@@ -122,12 +122,12 @@ class SystemdServiceTests(SystemdTest):
         self.systemctl('is-enabled', 'avahi-daemon.service')
 
 class SystemdJournalTests(SystemdTest):
-    @skipUnlessPassed('test_ssh')
+    @skipUnlessPassed('test_systemd_basic')
     def test_systemd_journal(self):
         (status, output) = self.target.run('journalctl')
         self.assertEqual(status, 0, output)
 
-    @skipUnlessPassed('test_systemd_basic')
+    @skipUnlessPassed('test_systemd_journal')
     def test_systemd_boot_time(self, systemd_TimeoutStartSec=90):
         """
         Compare the target boot time from journalctl against TimeoutStartSec
-- 
1.8.4.5




More information about the Openembedded-core mailing list