]> Sergey Matveev's repositories - vim-lsp.git/commitdiff
Fix test failure
authorYegappan Lakshmanan <yegappan@yahoo.com>
Sat, 8 Jul 2023 02:46:02 +0000 (19:46 -0700)
committerYegappan Lakshmanan <yegappan@yahoo.com>
Sat, 8 Jul 2023 02:46:02 +0000 (19:46 -0700)
test/clangd_tests.vim

index b32f06bc2b7950d57ed7d955d77b24fbefd2777d..68d074bb1e1aa93f3f1f1432386abdb1a47a3da0 100644 (file)
@@ -1517,22 +1517,19 @@ def g:Test_InlayHints()
   g:WaitForServerFileLoad(0)
   redraw!
 
+  assert_equal([], prop_list(7))
+
   :LspInlayHints enable
-  assert_equal([{id: -1, col: 9, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1},
-               {id: -2, col: 13, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1}],
-               prop_list(7))
+  var p = prop_list(7)
+  assert_equal([9, 'LspInlayHintsParam'], [p[0].col, p[0].type])
+  assert_equal([13, 'LspInlayHintsParam'], [p[1].col, p[1].type])
 
   :LspInlayHints disable
   assert_equal([], prop_list(7))
 
   g:LspOptionsSet({showInlayHints: true})
-  assert_equal([{id: -1, col: 9, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1},
-               {id: -2, col: 13, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1}],
-               prop_list(7))
+  assert_equal([9, 'LspInlayHintsParam'], [p[0].col, p[0].type])
+  assert_equal([13, 'LspInlayHintsParam'], [p[1].col, p[1].type])
 
   g:LspOptionsSet({showInlayHints: false})
   assert_equal([], prop_list(7))
@@ -1540,11 +1537,9 @@ def g:Test_InlayHints()
   :hide enew
   :LspInlayHints enable
   :bprev
-  assert_equal([{id: -1, col: 9, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1},
-               {id: -2, col: 13, type_bufnr: 0, end: 1,
-                type: 'LspInlayHintsParam', length: 1, start: 1}],
-               prop_list(7))
+  assert_equal([9, 'LspInlayHintsParam'], [p[0].col, p[0].type])
+  assert_equal([13, 'LspInlayHintsParam'], [p[1].col, p[1].type])
+
   :hide enew
   :LspInlayHints disable
   :bprev