Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion tests/test_filelock.py
Original file line number Diff line number Diff line change
Expand Up @@ -2042,7 +2042,9 @@ def test_final_symlink_backend_refuses_to_lock(tmp_path: Path) -> None:
(tmp_path / "link").symlink_to(tmp_path / "target")
# Keeping the final symlink a distinct key is safe because the backend still refuses to lock through it. O_NOFOLLOW
# reports the refusal as ELOOP on Linux and macOS, and as EFTYPE ("inappropriate file type") on NetBSD.
with pytest.raises(OSError, match=r"Too many levels of symbolic links|symbolic link|Inappropriate file type"):
with pytest.raises(
OSError, match=r"Too many levels of symbolic links|symbolic link|Inappropriate file type|Symbolic link loop"
):
FileLock(str(tmp_path / "link")).acquire()


Expand Down