diff options
author | Giampaolo Rodola <g.rodola@gmail.com> | 2020-05-12 21:26:14 +0200 |
---|---|---|
committer | Giampaolo Rodola <g.rodola@gmail.com> | 2020-05-12 21:26:14 +0200 |
commit | a78c1fd15aa3706331b1835dc6b3637b3e9fa845 (patch) | |
tree | 280d31de78605b6eac922d94588c8e28e5a6dd79 | |
parent | 12353e940fa5d8f75fe30a36a1dc9f11e082bbe3 (diff) | |
download | psutil-memleak-adjust.tar.gz |
adjust testmemleak-adjust
-rwxr-xr-x | psutil/tests/test_testutils.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/psutil/tests/test_testutils.py b/psutil/tests/test_testutils.py index 274de8ae..0bc6a218 100755 --- a/psutil/tests/test_testutils.py +++ b/psutil/tests/test_testutils.py @@ -361,6 +361,7 @@ class TestMemLeakClass(TestMemoryLeak): self.assertRaises(ValueError, self.execute, lambda: 0, times=-1) self.assertRaises(ValueError, self.execute, lambda: 0, warmup_times=-1) self.assertRaises(ValueError, self.execute, lambda: 0, tolerance=-1) + self.assertRaises(ValueError, self.execute, lambda: 0, retries=0) def test_leak(self): ls = [] @@ -385,9 +386,7 @@ class TestMemLeakClass(TestMemoryLeak): def test_execute_w_exc(self): def fun(): 1 / 0 - # XXX: use high tolerance, occasional false positive - self.execute_w_exc(ZeroDivisionError, fun, times=2000, - warmup_times=20, tolerance=200 * 1024) + self.execute_w_exc(ZeroDivisionError, fun) with self.assertRaises(ZeroDivisionError): self.execute_w_exc(OSError, fun) |