Skip to content

Commit 454f588

Browse files
committed
Readd FFIWrapper.getwinerror for the mock to override
1 parent 65144c7 commit 454f588

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/trio/_core/_tests/test_windows.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@
3939
def test_winerror(monkeypatch: pytest.MonkeyPatch) -> None:
4040
# this is unfortunately needed as the generated ffi is read-only
4141
class FFIWrapper:
42-
pass
42+
def getwinerror(self) -> None:
43+
raise NotImplementedError("this is a fake implementation")
4344

4445
mock = create_autospec(ffi.getwinerror)
4546
monkeypatch.setattr("trio._core._windows_cffi.ffi", FFIWrapper)

0 commit comments

Comments
 (0)