aboutsummaryrefslogtreecommitdiff
path: root/test/functional/fixtures/fake-lsp-server.lua
diff options
context:
space:
mode:
authorMichael Lingelbach <m.j.lbach@gmail.com>2022-04-30 06:36:40 -0700
committerGitHub <noreply@github.com>2022-04-30 15:36:40 +0200
commit5b04e46d23b65413d934d812d61d8720b815eb1c (patch)
treef39fb4ef457aa7cdce509806c87972d3c47164fa /test/functional/fixtures/fake-lsp-server.lua
parenteecc6535eb5d0a6b9465489e69cbde1cbb8276e6 (diff)
downloadrneovim-5b04e46d23b65413d934d812d61d8720b815eb1c.tar.gz
rneovim-5b04e46d23b65413d934d812d61d8720b815eb1c.tar.bz2
rneovim-5b04e46d23b65413d934d812d61d8720b815eb1c.zip
feat(lsp): add vim.lsp.buf.format (#18193)
Diffstat (limited to 'test/functional/fixtures/fake-lsp-server.lua')
-rw-r--r--test/functional/fixtures/fake-lsp-server.lua20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/functional/fixtures/fake-lsp-server.lua b/test/functional/fixtures/fake-lsp-server.lua
index bd59e5dc1f..5403405905 100644
--- a/test/functional/fixtures/fake-lsp-server.lua
+++ b/test/functional/fixtures/fake-lsp-server.lua
@@ -744,6 +744,26 @@ function tests.clientside_commands()
}
end
+
+function tests.basic_formatting()
+ skeleton {
+ on_init = function()
+ return {
+ capabilities = {
+ documentFormattingProvider = true,
+ }
+ }
+ end;
+ body = function()
+ notify('start')
+ expect_request('textDocument/formatting', function()
+ return nil, {}
+ end)
+ notify('shutdown')
+ end;
+ }
+end
+
-- Tests will be indexed by TEST_NAME
local kill_timer = vim.loop.new_timer()