aboutsummaryrefslogtreecommitdiff
path: root/test/functional/api/vim_spec.lua
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-07-02 19:35:11 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-07-03 04:34:28 +0800
commit7a907c3314f939a3d2983ac07edc5c9672957352 (patch)
treec90e1d89fd93df88bf6938018ada5bf4a98ec7ba /test/functional/api/vim_spec.lua
parentf93eb169f6e1d72646556153fc0d01b3c843498a (diff)
downloadrneovim-7a907c3314f939a3d2983ac07edc5c9672957352.tar.gz
rneovim-7a907c3314f939a3d2983ac07edc5c9672957352.tar.bz2
rneovim-7a907c3314f939a3d2983ac07edc5c9672957352.zip
feat(api): add `unsilent` to command APIs
Diffstat (limited to 'test/functional/api/vim_spec.lua')
-rw-r--r--test/functional/api/vim_spec.lua61
1 files changed, 36 insertions, 25 deletions
diff --git a/test/functional/api/vim_spec.lua b/test/functional/api/vim_spec.lua
index 002bcd92a4..989ed27e16 100644
--- a/test/functional/api/vim_spec.lua
+++ b/test/functional/api/vim_spec.lua
@@ -3181,10 +3181,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('echo foo', {}))
end)
@@ -3221,10 +3222,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('4,6s/math.random/math.max/', {}))
end)
@@ -3261,10 +3263,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('buffer 1', {}))
end)
@@ -3301,10 +3304,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('put +', {}))
end)
@@ -3341,10 +3345,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('1,3delete * 5', {}))
end)
@@ -3381,10 +3386,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
},
}, meths.parse_cmd('w!', {}))
end)
@@ -3421,10 +3427,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = true,
- vertical = false,
split = "topleft",
tab = 2,
- verbose = 15
+ unsilent = false,
+ verbose = 15,
+ vertical = false,
},
}, meths.parse_cmd('15verbose silent! aboveleft topleft tab filter /foo/ split foo.txt', {}))
eq({
@@ -3443,7 +3450,7 @@ describe('API', function()
nextcmd = '',
mods = {
browse = false,
- confirm = false,
+ confirm = true,
emsg_silent = false,
filter = {
pattern = "foo",
@@ -3459,12 +3466,13 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
- split = "",
+ split = "botright",
tab = 0,
- verbose = -1
+ unsilent = true,
+ verbose = 0,
+ vertical = false,
},
- }, meths.parse_cmd('filter! /foo/ split foo.txt', {}))
+ }, meths.parse_cmd('0verbose unsilent botright confirm filter! /foo/ split foo.txt', {}))
end)
it('works with user commands', function()
command('command -bang -nargs=+ -range -addr=lines MyCommand echo foo')
@@ -3500,10 +3508,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('4,6MyCommand! test it', {}))
end)
@@ -3540,10 +3549,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('argadd a.txt | argadd b.txt', {}))
end)
@@ -3581,10 +3591,11 @@ describe('API', function()
noswapfile = false,
sandbox = false,
silent = false,
- vertical = false,
split = "",
tab = 0,
- verbose = -1
+ unsilent = false,
+ verbose = -1,
+ vertical = false,
}
}, meths.parse_cmd('MyCommand test it', {}))
end)