test: check the next elapse timer timestamp after deserialization
When deserializing a serialized timer unit with RandomizedDelaySec= set, systemd should use the last inactive exit timestamp instead of current realtime to calculate the new next elapse, so the timer unit actually runs in the given calendar window. Provides coverage for: - https://github.com/systemd/systemd/issues/18678 - https://github.com/systemd/systemd/pull/27752
This commit is contained in:
@@ -57,6 +57,15 @@ assert_le() {(
|
||||
fi
|
||||
)}
|
||||
|
||||
assert_ge() {(
|
||||
set +ex
|
||||
|
||||
if [[ "${1:?}" -lt "${2:?}" ]]; then
|
||||
echo "FAIL: '$1' < '$2'" >&2
|
||||
exit 1
|
||||
fi
|
||||
)}
|
||||
|
||||
assert_in() {(
|
||||
set +ex
|
||||
|
||||
|
||||
Reference in New Issue
Block a user