aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMathias Fussenegger <f.mathias@zignar.net>2021-04-14 21:42:03 +0200
committerMathias Fussenegger <f.mathias@zignar.net>2021-04-14 21:42:03 +0200
commit046991e4d5c6bc25ee11bbe28f0b685f00cf1d3d (patch)
tree4be3e72e7c455aeb94ec0eaa0f663d14387f2a6d /test
parentb67f689e4cb08ac3f33432038ae9aec81383a9f3 (diff)
downloadrneovim-046991e4d5c6bc25ee11bbe28f0b685f00cf1d3d.tar.gz
rneovim-046991e4d5c6bc25ee11bbe28f0b685f00cf1d3d.tar.bz2
rneovim-046991e4d5c6bc25ee11bbe28f0b685f00cf1d3d.zip
lsp: Remove vim.NIL handling from apply_text_document_edit
The rpc layer normalizes `vim.NIL` to `nil`, so the scenario tested should never happen.
Diffstat (limited to 'test')
-rw-r--r--test/functional/plugin/lsp_spec.lua13
1 files changed, 0 insertions, 13 deletions
diff --git a/test/functional/plugin/lsp_spec.lua b/test/functional/plugin/lsp_spec.lua
index 49e443d56c..557f8a206f 100644
--- a/test/functional/plugin/lsp_spec.lua
+++ b/test/functional/plugin/lsp_spec.lua
@@ -1137,19 +1137,6 @@ describe('LSP', function()
'2nd line of 语text';
}, buf_lines(target_bufnr))
end)
- it('correctly goes ahead with the edit if the version is vim.NIL', function()
- -- we get vim.NIL when we decode json null value.
- local json = exec_lua[[
- return vim.fn.json_decode("{ \"a\": 1, \"b\": null }")
- ]]
- eq(json.b, exec_lua("return vim.NIL"))
-
- exec_lua('vim.lsp.util.apply_text_document_edit(...)', text_document_edit(exec_lua("return vim.NIL")))
- eq({
- 'First ↥ 🤦 🦄 line of text';
- '2nd line of 语text';
- }, buf_lines(target_bufnr))
- end)
it('skips the edit if the version of the edit is behind the local buffer ', function()
local apply_edit_mocking_current_version = function(edit, versionedBuf)
exec_lua([[