diff src/testdir/test_findfile.vim @ 17849:73ddc462979d v8.1.1921

patch 8.1.1921: more functions can be used as methods Commit: https://github.com/vim/vim/commit/a4208966fb289a505ebdef62bbc37c214069bab4 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Aug 24 20:50:19 2019 +0200 patch 8.1.1921: more functions can be used as methods Problem: More functions can be used as methods. Solution: Make various functions usable as a method.
author Bram Moolenaar <Bram@vim.org>
date Sat, 24 Aug 2019 21:00:05 +0200
parents 6839f99d2269
children 26a04a556982
line wrap: on
line diff
--- a/src/testdir/test_findfile.vim
+++ b/src/testdir/test_findfile.vim
@@ -50,7 +50,7 @@ func Test_findfile()
   set path=.
   call assert_equal('Xdir2/foo',    findfile('foo'))
   call assert_equal('',             findfile('bar'))
-  call assert_equal('Xdir2/foobar', findfile('foobar'))
+  call assert_equal('Xdir2/foobar', 'foobar'->findfile())
 
   " Empty {path} 2nd argument is the same as no 2nd argument.
   call assert_equal('Xdir2/foo', findfile('foo', ''))
@@ -137,7 +137,7 @@ func Test_finddir()
   cd Xdir1
 
   call assert_equal('Xdir2', finddir('Xdir2'))
-  call assert_equal('',      finddir('Xdir3'))
+  call assert_equal('',      'Xdir3'->finddir())
 
   " Files should not be found (findfile() finds them).
   call assert_equal('', finddir('foo'))