test(client): cover Vim/Neovim link-follow command surface + tab-drop

Add SplitLink/VSplitLink/TabnewLink/TabDropLink/GoBackLink to both
keymap harness command lists, plus a smoke check that
nuwiki.commands.follow_link_drop is callable.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-31 07:54:25 -03:00
parent f65d861f72
commit 82b6bc9c60
2 changed files with 7 additions and 0 deletions
+1
View File
@@ -103,6 +103,7 @@ endif
let s:both_forms = [ let s:both_forms = [
\ 'Index', 'TabIndex', 'UISelect', 'Goto', 'FollowLink', 'Backlinks', \ 'Index', 'TabIndex', 'UISelect', 'Goto', 'FollowLink', 'Backlinks',
\ 'SplitLink', 'VSplitLink', 'TabnewLink', 'TabDropLink', 'GoBackLink',
\ 'NextLink', 'PrevLink', 'BaddLink', 'RenameFile', 'DeleteFile', \ 'NextLink', 'PrevLink', 'BaddLink', 'RenameFile', 'DeleteFile',
\ 'MakeDiaryNote', 'TabMakeDiaryNote', 'MakeYesterdayDiaryNote', \ 'MakeDiaryNote', 'TabMakeDiaryNote', 'MakeYesterdayDiaryNote',
\ 'MakeTomorrowDiaryNote', \ 'MakeTomorrowDiaryNote',
+6
View File
@@ -130,6 +130,7 @@ vim.defer_fn(function()
-- nuwiki-only maintenance command with no :Vimwiki* alias. -- nuwiki-only maintenance command with no :Vimwiki* alias.
local both_forms = { local both_forms = {
'Index', 'TabIndex', 'UISelect', 'Goto', 'FollowLink', 'Backlinks', 'Index', 'TabIndex', 'UISelect', 'Goto', 'FollowLink', 'Backlinks',
'SplitLink', 'VSplitLink', 'TabnewLink', 'TabDropLink', 'GoBackLink',
'NextLink', 'PrevLink', 'BaddLink', 'RenameFile', 'DeleteFile', 'NextLink', 'PrevLink', 'BaddLink', 'RenameFile', 'DeleteFile',
'MakeDiaryNote', 'TabMakeDiaryNote', 'MakeYesterdayDiaryNote', 'MakeDiaryNote', 'TabMakeDiaryNote', 'MakeYesterdayDiaryNote',
'MakeTomorrowDiaryNote', 'MakeTomorrowDiaryNote',
@@ -167,6 +168,11 @@ vim.defer_fn(function()
local exists = vim.fn.exists(':' .. cmd) == 2 local exists = vim.fn.exists(':' .. cmd) == 2
record(exists, 'surface.' .. cmd, exists and '' or (':' .. cmd .. ' not registered')) record(exists, 'surface.' .. cmd, exists and '' or (':' .. cmd .. ' not registered'))
end end
do
local callable = type(require('nuwiki.commands').follow_link_drop) == 'function'
record(callable, 'direct.follow_link_drop_callable',
callable and '' or 'nuwiki.commands.follow_link_drop is not a function')
end
-- ===== Pure-Lua command invocation (cursor movement) ===== -- ===== Pure-Lua command invocation (cursor movement) =====
-- :NuwikiNextLink / :NuwikiPrevLink wrap the link-search motion and run -- :NuwikiNextLink / :NuwikiPrevLink wrap the link-search motion and run