From: Michal Sekletar Date: Wed, 13 Jul 2022 14:45:54 +0000 (+0200) Subject: Revert "tests: add test for handling of background sessions" X-Git-Tag: v252-rc1~649^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=527e0e8188221fcffb39fded2232f20ded2eaae3;p=thirdparty%2Fsystemd.git Revert "tests: add test for handling of background sessions" This reverts commit bf40417c7cbe0afb185eda97ea46395b1bb74bdf. --- diff --git a/test/TEST-35-LOGIN/test.sh b/test/TEST-35-LOGIN/test.sh index add862c962a..808f94a58ff 100755 --- a/test/TEST-35-LOGIN/test.sh +++ b/test/TEST-35-LOGIN/test.sh @@ -8,7 +8,7 @@ TEST_DESCRIPTION="Tests for systemd-logind" . "${TEST_BASE_DIR:?}/test-functions" test_append_files() { - image_install -o evemu-device evemu-event crond crontab + image_install -o evemu-device evemu-event } do_test "$@" diff --git a/test/units/testsuite-35.sh b/test/units/testsuite-35.sh index 33b5fbf1ee3..fa90bc6d734 100755 --- a/test/units/testsuite-35.sh +++ b/test/units/testsuite-35.sh @@ -430,50 +430,6 @@ EOF fi } -teardown_cron() ( - set +ex - - pkill -u "$(id -u logind-test-user)" - sleep 1 - pkill -KILL -u "$(id -u logind-test-user)" - pkill crond - crontab -r -u logind-test-user - - return 0 -) - -test_no_user_instance_for_cron() { - if ! command -v crond || ! command -v crontab ; then - echo "Skipping test for background cron sessions because cron is missing." - return - fi - - trap teardown_cron RETURN - - # Setup cron - crond -s -n & - # Install crontab for the test user that runs sleep every minute. But let's sleep for - # 65 seconds to make sure there is overlap between two consecutive runs, i.e. we have - # always a cron session running. - crontab -u logind-test-user - <