From 3c4e972d6d0945a5401377bed25b307a88b19c75 Mon Sep 17 00:00:00 2001 From: Barney Gale Date: Fri, 5 Jan 2024 21:41:19 +0000 Subject: GH-113568: Stop raising auditing events from pathlib ABCs (#113571) Raise auditing events in `pathlib.Path.glob()`, `rglob()` and `walk()`, but not in `pathlib._abc.PathBase` methods. Also move generation of a deprecation warning into `pathlib.Path` so it gets the right stack level. --- Lib/test/test_pathlib/test_pathlib_abc.py | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'Lib/test/test_pathlib/test_pathlib_abc.py') diff --git a/Lib/test/test_pathlib/test_pathlib_abc.py b/Lib/test/test_pathlib/test_pathlib_abc.py index e4a4e81e547..a67235b4da3 100644 --- a/Lib/test/test_pathlib/test_pathlib_abc.py +++ b/Lib/test/test_pathlib/test_pathlib_abc.py @@ -1266,19 +1266,6 @@ class DummyPathTest(DummyPurePathTest): bad_link.symlink_to("bad" * 200) self.assertEqual(sorted(base.glob('**/*')), [bad_link]) - def test_glob_recursive_no_trailing_slash(self): - P = self.cls - p = P(self.base) - with self.assertWarns(FutureWarning): - p.glob('**') - with self.assertWarns(FutureWarning): - p.glob('*/**') - with self.assertWarns(FutureWarning): - p.rglob('**') - with self.assertWarns(FutureWarning): - p.rglob('*/**') - - def test_readlink(self): if not self.can_symlink: self.skipTest("symlinks required") -- cgit v1.2.3