mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
LSP: Resolve text_document_save capability according to spec
Fixes https://github.com/neovim/neovim/issues/13989 See https://github.com/microsoft/language-server-protocol/issues/288
This commit is contained in:
parent
e55ded00cf
commit
eff7666163
@ -938,7 +938,7 @@ function protocol.resolve_capabilities(server_capabilities)
|
||||
text_document_did_change = textDocumentSync;
|
||||
text_document_will_save = false;
|
||||
text_document_will_save_wait_until = false;
|
||||
text_document_save = false;
|
||||
text_document_save = true;
|
||||
text_document_save_include_text = false;
|
||||
}
|
||||
elseif type(textDocumentSync) == 'table' then
|
||||
|
@ -333,6 +333,7 @@ describe('LSP', function()
|
||||
client.stop()
|
||||
local full_kind = exec_lua("return require'vim.lsp.protocol'.TextDocumentSyncKind.Full")
|
||||
eq(full_kind, client.resolved_capabilities().text_document_did_change)
|
||||
eq(true, client.resolved_capabilities().text_document_save)
|
||||
end;
|
||||
on_exit = function(code, signal)
|
||||
eq(0, code, "exit code", fake_lsp_logfile)
|
||||
|
Loading…
Reference in New Issue
Block a user