]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.9] bpo-46426: Improve tests for the dir_fd argument (GH-30668) (GH-30757)
authorSerhiy Storchaka <storchaka@gmail.com>
Mon, 24 Jan 2022 10:14:42 +0000 (12:14 +0200)
committerGitHub <noreply@github.com>
Mon, 24 Jan 2022 10:14:42 +0000 (12:14 +0200)
commit3f1ea163ea54513e00e0e9d5442fee1b639825cc
treea7b1b59d34cd6ab37cf69dc15bbb82e9315089ea
parent1398dca838529e682c06b496cc1911d91334ff3a
[3.9] bpo-46426: Improve tests for the dir_fd argument (GH-30668) (GH-30757)

Ensure that directory file descriptors refer to directories different
from the current directory, and that src_dir_fd and dst_dir_fd refer
to different directories.

Add context manager open_dir_fd() in test.support.os_helper.
(cherry picked from commit 54610bb448a9cf5be77d53b66169fca4c11be6cb)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Lib/test/support/__init__.py
Lib/test/test_os.py
Lib/test/test_posix.py