]> granicus.if.org Git - vim/commitdiff
patch 9.0.0330: method tests fail v9.0.0330
authorBram Moolenaar <Bram@vim.org>
Tue, 30 Aug 2022 15:40:45 +0000 (16:40 +0100)
committerBram Moolenaar <Bram@vim.org>
Tue, 30 Aug 2022 15:40:45 +0000 (16:40 +0100)
Problem:    Method tests fail.
Solution:   Adjust for change of items().

src/testdir/test_method.vim
src/version.c

index 6b62d36209920a8df4b4dd34681825f9f159ab27..ee2093f285f2469764bff4b73ad4f3919237635a 100644 (file)
@@ -20,9 +20,8 @@ func Test_list_method()
   call assert_equal(2, l->get(1))
   call assert_equal(1, l->index(2))
   call assert_equal([0, 1, 2, 3], [1, 2, 3]->insert(0))
-  call assert_fails('eval l->items()', 'E715:')
   call assert_equal('1 2 3', l->join())
-  call assert_fails('eval l->keys()', 'E715:')
+  call assert_fails('eval l->keys()', 'E1206:')
   call assert_equal(3, l->len())
   call assert_equal([2, 3, 4], [1, 2, 3]->map('v:val + 1'))
   call assert_equal(3, l->max())
@@ -34,7 +33,7 @@ func Test_list_method()
   call assert_equal('[1, 2, 3]', l->string())
   call assert_equal(v:t_list, l->type())
   call assert_equal([1, 2, 3], [1, 1, 2, 3, 3]->uniq())
-  call assert_fails('eval l->values()', 'E715:')
+  call assert_fails('eval l->values()', 'E1206:')
   call assert_fails('echo []->len', 'E107:')
 endfunc
 
@@ -79,6 +78,7 @@ func Test_string_method()
   eval "a\rb\ec"->strtrans()->assert_equal('a^Mb^[c')
   eval "aあb"->strwidth()->assert_equal(4)
   eval 'abc'->substitute('b', 'x', '')->assert_equal('axc')
+  call assert_fails('eval "x"->items()', 'E1227:')
 
   eval 'abc'->printf('the %s arg')->assert_equal('the abc arg')
 endfunc
index e9c925017ac531b0d88d0ceb7aa52b0551c3d845..87881f17d77def3e6a55881c1f5d7326979475e8 100644 (file)
@@ -707,6 +707,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    330,
 /**/
     329,
 /**/