From c49a6771f76242e7e00f0024abe21bf64d41baa0 Mon Sep 17 00:00:00 2001
From: Yu Watanabe <watanabe.yu+github@gmail.com>
Date: Fri, 17 May 2024 13:25:25 +0900
Subject: [PATCH 0643/1160] test: wait for slice unit being (de)activated
Fixes #32731.
(cherry picked from commit 272aae38f89d0c415a57370a624287cd5aeaec0b)
test/units/testsuite-15.sh | 4 ++++
1 file changed, 4 insertions(+)
@@ -256,6 +256,8 @@ EOF
'MemoryMax' t 1000000002 \
0
+ timeout 1m bash -c 'until systemctl is-active a-b-c.slice; do sleep 1s; done'
+
# The override takes precedence for MemoryMax
check_ok a-b-c.slice MemoryMax "1000000000"
# The transient setting replaces the default
@@ -273,6 +275,8 @@ EOF
StopUnit 'ss' \
'a-b-c.slice' 'replace'
+ timeout 1m bash -c 'while systemctl is-active a-b-c.slice; do sleep 1s; done'
+
rm -f "/run/systemd/system/$dropin/override.conf"
done
--
2.33.0