]> git.ipfire.org Git - thirdparty/libcgroup.git/commitdiff
ftests/086: skip test on non-systemd configuration
authorKamalesh Babulal <kamalesh.babulal@oracle.com>
Wed, 29 Nov 2023 09:43:48 +0000 (09:43 +0000)
committerTom Hromatka <tom.hromatka@oracle.com>
Thu, 7 Dec 2023 15:58:13 +0000 (08:58 -0700)
Skip running the testcase, when compiled with --enable-systemd=no,
using Systemd.is_systemd_enabled().

Signed-off-by: Kamalesh Babulal <kamalesh.babulal@oracle.com>
Signed-off-by: Tom Hromatka <tom.hromatka@oracle.com>
tests/ftests/086-sudo-systemd_cmdline_example.py

index 801027d5c4a2763e9f6b370dfede26101d3f4003..23dc0c940a499cf0a98ff851812a2494f6bd2b67 100755 (executable)
@@ -44,6 +44,10 @@ def prereqs(config):
         result = consts.TEST_SKIPPED
         cause = 'This test requires the unified cgroup hierarchy'
 
+    if not Systemd.is_systemd_enabled():
+        result = consts.TEST_SKIPPED
+        cause = 'Systemd support not compiled in'
+
     return result, cause