]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.1.0332: tests: some assert_equal() calls have wrong order of args v9.1.0332
authorzeertzjq <zeertzjq@outlook.com>
Mon, 15 Apr 2024 17:01:04 +0000 (19:01 +0200)
committerChristian Brabandt <cb@256bit.org>
Mon, 15 Apr 2024 17:01:04 +0000 (19:01 +0200)
Problem:  tests: some assert_equal() calls have wrong order of args
Solution: Correct the order (zeertzjq).

closes: #14555

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
src/testdir/test_cmdline.vim
src/testdir/test_digraph.vim
src/testdir/test_registers.vim
src/version.c

index d4fb47b5c60c59f654b999f2f0781356182a6263..ed8f89dd597b29e2395cb738f76eee0db013e238 100644 (file)
@@ -3733,9 +3733,9 @@ func Test_custom_completion()
   call assert_fails("call getcompletion('', 'custom')", 'E475:')
   call assert_fails("call getcompletion('', 'customlist')", 'E475:')
 
-  call assert_equal(getcompletion('', 'custom,CustomComplete1'), ['a', 'b', 'c'])
-  call assert_equal(getcompletion('', 'customlist,CustomComplete2'), ['a', 'b'])
-  call assert_equal(getcompletion('b', 'customlist,CustomComplete2'), ['b'])
+  call assert_equal(['a', 'b', 'c'], getcompletion('', 'custom,CustomComplete1'))
+  call assert_equal(['a', 'b'], getcompletion('', 'customlist,CustomComplete2'))
+  call assert_equal(['b'], getcompletion('b', 'customlist,CustomComplete2'))
 
   delcom Test1
   delcom Test2
index 4aed403cdab412ab2cae9a1a0347d8df18e4c598..3312faf31f62d5bf45a00f45204f5f6ddb4c0403 100644 (file)
@@ -595,13 +595,13 @@ func Test_digraph_getlist_function()
   call digraph_setlist([['aa', 'き'], ['bb', 'く']])
 
   for pair in digraph_getlist(1)
-    call assert_equal(digraph_get(pair[0]), pair[1])
+    call assert_equal(pair[1], digraph_get(pair[0]))
   endfor
 
   " We don't know how many digraphs are registered before, so check the number
   " of digraphs returned.
   call assert_equal(digraph_getlist()->len(), digraph_getlist(0)->len())
-  call assert_notequal((digraph_getlist()->len()), digraph_getlist(1)->len())
+  call assert_notequal(digraph_getlist()->len(), digraph_getlist(1)->len())
 
   call assert_fails('call digraph_getlist(0z12)', 'E974: Using a Blob as a Number')
 endfunc
index cbe6fa68056671bfc723d91fda81a5ef44c8c8c1..1d377bdd417732dffe2aa59e0e28734298a0bdf1 100644 (file)
@@ -797,13 +797,13 @@ func Test_ve_blockpaste()
   call cursor(1,1)
   exe ":norm! \<C-V>3ljdP"
   call assert_equal(1, col('.'))
-  call assert_equal(getline(1, 2), ['QWERTZ', 'ASDFGH'])
+  call assert_equal(['QWERTZ', 'ASDFGH'], getline(1, 2))
   call cursor(1,1)
   exe ":norm! \<C-V>3ljd"
   call cursor(1,1)
   norm! $3lP
   call assert_equal(5, col('.'))
-  call assert_equal(getline(1, 2), ['TZ  QWER', 'GH  ASDF'])
+  call assert_equal(['TZ  QWER', 'GH  ASDF'], getline(1, 2))
   set ve&vim
   bwipe!
 endfunc
index 193c92515fe4f236ede373160fe225042f3cde21..1d8e1e33653aeb625a3e079382ec4b0ea4cbbe49 100644 (file)
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    332,
 /**/
     331,
 /**/