diff options
author | Giampaolo Rodola <g.rodola@gmail.com> | 2022-10-19 02:28:14 +0200 |
---|---|---|
committer | Giampaolo Rodola <g.rodola@gmail.com> | 2022-10-19 02:28:14 +0200 |
commit | aa9a4f6f9bfaca1dd1d22034d007bbf5d86b9670 (patch) | |
tree | 106256b2c758aa7253c6b23a67b0938f0795acc2 /psutil/tests/test_process.py | |
parent | 1da9f7928e79ecc127768e7a5bc4eb7f785f4513 (diff) | |
download | psutil-linux-zombie-proc.tar.gz |
raise ZombieProcess instead of AccessDenied if process is a zombielinux-zombie-proc
Diffstat (limited to 'psutil/tests/test_process.py')
-rwxr-xr-x | psutil/tests/test_process.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py index 26869e98..bd31ac66 100755 --- a/psutil/tests/test_process.py +++ b/psutil/tests/test_process.py @@ -1324,6 +1324,12 @@ class TestProcess(PsutilTestCase): for fun, name in ns.iter(ns.all): succeed_or_zombie_p_exc(fun) + if LINUX: + # TODO: broken + # self.assertRaises(psutil.ZombieProcess, zproc.exe) + self.assertRaises(psutil.ZombieProcess, zproc.cwd) + self.assertRaises(psutil.ZombieProcess, zproc.memory_full_info) + assert psutil.pid_exists(zproc.pid) self.assertIn(zproc.pid, psutil.pids()) self.assertIn(zproc.pid, [x.pid for x in psutil.process_iter()]) |