fix: lint warning and test mocks for async file read

Problem: selene flagged unused err3 variable, and test mock_enums
still mocked io.open instead of the new vim.uv.fs_* calls.

Solution: rename err3 to _, replace io.open mock with synchronous
vim.uv.fs_open/fs_fstat/fs_read/fs_close mocks using a sentinel fd.
This commit is contained in:
Barrett Ruth 2026-02-22 23:21:06 -05:00
parent 71d5505fb8
commit 3776133815
Signed by: barrett
GPG key ID: A6C96C9349D2FC81
2 changed files with 35 additions and 13 deletions

View file

@ -193,7 +193,7 @@ function M:get_completions(ctx, callback)
on_all_done()
return
end
vim.uv.fs_read(fd, stat.size, 0, function(err3, data)
vim.uv.fs_read(fd, stat.size, 0, function(_, data)
vim.uv.fs_close(fd)
enums_content = data or ''
on_all_done()