aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/test_pathlib/test_pathlib_abc.py
diff options
context:
space:
mode:
authorBarney Gale <barney.gale@gmail.com>2023-12-22 17:49:09 +0000
committerGitHub <noreply@github.com>2023-12-22 17:49:09 +0000
commitff5e131df5f374f72579b970856dc5646e8b836c (patch)
tree0f8497d15de8f9e3df09ca043ad586ff0bcf1365 /Lib/test/test_pathlib/test_pathlib_abc.py
parent4a3d2419bb5b7cd862e3d909f53a2ef0a09cdcee (diff)
downloadcpython-ff5e131df5f374f72579b970856dc5646e8b836c.tar.gz
cpython-ff5e131df5f374f72579b970856dc5646e8b836c.zip
GH-112855: Slightly improve tests for `pathlib.PurePath` pickling (#113243)
Add a few more simple test cases, like non-anchored paths. Remove misplaced and indirect test that pickling doesn't change the `stat()` value.
Diffstat (limited to 'Lib/test/test_pathlib/test_pathlib_abc.py')
-rw-r--r--Lib/test/test_pathlib/test_pathlib_abc.py8
1 files changed, 0 insertions, 8 deletions
diff --git a/Lib/test/test_pathlib/test_pathlib_abc.py b/Lib/test/test_pathlib/test_pathlib_abc.py
index 6748def91a1..42575a5e640 100644
--- a/Lib/test/test_pathlib/test_pathlib_abc.py
+++ b/Lib/test/test_pathlib/test_pathlib_abc.py
@@ -3,7 +3,6 @@ import io
import os
import errno
import pathlib
-import pickle
import posixpath
import stat
import unittest
@@ -1644,13 +1643,6 @@ class DummyPathTest(DummyPurePathTest):
self.assertIs((P / 'fileA\udfff').is_char_device(), False)
self.assertIs((P / 'fileA\x00').is_char_device(), False)
- def test_pickling_common(self):
- p = self.cls(self.base, 'fileA')
- for proto in range(0, pickle.HIGHEST_PROTOCOL + 1):
- dumped = pickle.dumps(p, proto)
- pp = pickle.loads(dumped)
- self.assertEqual(pp.stat(), p.stat())
-
def test_parts_interning(self):
P = self.cls
p = P('/usr/bin/foo')