]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test: add brief testcase for systemd-run disconnect handling 34884/head
authorLennart Poettering <lennart@poettering.net>
Fri, 25 Oct 2024 09:31:38 +0000 (11:31 +0200)
committerLennart Poettering <lennart@poettering.net>
Fri, 25 Oct 2024 15:51:04 +0000 (17:51 +0200)
test/units/TEST-74-AUX-UTILS.run.sh

index 903ddde70efc31db15e4639b5014de8f997fc9dd..83ae352943f6975e4d10cb6770ff4d9348c3d0f2 100755 (executable)
@@ -272,3 +272,6 @@ if [[ -e /usr/lib/pam.d/systemd-run0 ]] || [[ -e /etc/pam.d/systemd-run0 ]]; the
     assert_neq "$(run0 --pty tty < /dev/null)" "not a tty"
     assert_eq "$(run0 --pipe tty < /dev/null)" "not a tty"
 fi
+
+# Tests whether intermediate disconnects corrupt us (modified testcase from https://github.com/systemd/systemd/issues/27204)
+assert_rc "37" systemd-run --unit=disconnecttest --wait --pipe --user -M testuser@.host bash -ec 'systemctl --user daemon-reexec; sleep 3; exit 37'