aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir/test_functions.vim
diff options
context:
space:
mode:
authorSean Dewar <seandewar@users.noreply.github.com>2021-08-07 17:06:08 +0100
committerSean Dewar <seandewar@users.noreply.github.com>2021-08-12 22:35:24 +0100
commit5fbc1a49c719c0c93fa73277ac30d17f797d096d (patch)
treec23089dd05097a388cad40e42d284ffdb78fcd90 /src/nvim/testdir/test_functions.vim
parent41dbd3a2e05f5f4d59e076f8b8c82ad974d2bbd5 (diff)
downloadrneovim-5fbc1a49c719c0c93fa73277ac30d17f797d096d.tar.gz
rneovim-5fbc1a49c719c0c93fa73277ac30d17f797d096d.tar.bz2
rneovim-5fbc1a49c719c0c93fa73277ac30d17f797d096d.zip
vim-patch:8.1.1888: more functions can be used as methods
Problem: More functions can be used as methods. Solution: Make various functions usable as a method. https://github.com/vim/vim/commit/073e4b92e613d22ce7b16e0fbf5c0e40cb5f9b2c test_popup.vim already has the changes from this patch (they're N/A anyway).
Diffstat (limited to 'src/nvim/testdir/test_functions.vim')
-rw-r--r--src/nvim/testdir/test_functions.vim6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/testdir/test_functions.vim b/src/nvim/testdir/test_functions.vim
index 2493cc2e27..1c56e936a8 100644
--- a/src/nvim/testdir/test_functions.vim
+++ b/src/nvim/testdir/test_functions.vim
@@ -1414,12 +1414,12 @@ func Test_bufadd_bufload()
let curbuf = bufnr('')
call writefile(['some', 'text'], 'XotherName')
- let buf = bufadd('XotherName')
+ let buf = 'XotherName'->bufadd()
call assert_notequal(0, buf)
- call assert_equal(1, bufexists('XotherName'))
+ eval 'XotherName'->bufexists()->assert_equal(1)
call assert_equal(0, getbufvar(buf, '&buflisted'))
call assert_equal(0, bufloaded(buf))
- call bufload(buf)
+ eval buf->bufload()
call assert_equal(1, bufloaded(buf))
call assert_equal(['some', 'text'], getbufline(buf, 1, '$'))
call assert_equal(curbuf, bufnr(''))