summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0817
blob: c7a040249c27b5e9e8afc234682b9e468e913761 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
To: vim_dev@googlegroups.com
Subject: Patch 8.1.0817
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 8.1.0817
Problem:    ":=" command is not tested.
Solution:   Add a test. (Dominique Pelle, closes #3859)
Files:	    src/testdir/Make_all.mak, src/testdir/test_alot.vim,
            src/testdir/test_ex_equal.vim


*** ../vim-8.1.0816/src/testdir/Make_all.mak	2019-01-24 21:57:11.574719854 +0100
--- src/testdir/Make_all.mak	2019-01-24 22:39:20.598524877 +0100
***************
*** 105,110 ****
--- 105,111 ----
  	test_erasebackword \
  	test_escaped_glob \
  	test_eval_stuff \
+ 	test_ex_equal \
  	test_ex_undo \
  	test_ex_z \
  	test_exit \
*** ../vim-8.1.0816/src/testdir/test_alot.vim	2018-11-10 18:54:40.656592081 +0100
--- src/testdir/test_alot.vim	2019-01-24 22:39:20.598524877 +0100
***************
*** 10,15 ****
--- 10,16 ----
  source test_compiler.vim
  source test_cursor_func.vim
  source test_delete.vim
+ source test_ex_equal.vim
  source test_ex_undo.vim
  source test_ex_z.vim
  source test_execute_func.vim
*** ../vim-8.1.0816/src/testdir/test_ex_equal.vim	2019-01-24 22:42:00.857403287 +0100
--- src/testdir/test_ex_equal.vim	2019-01-24 22:39:20.598524877 +0100
***************
*** 0 ****
--- 1,32 ----
+ " Test Ex := command.
+ 
+ func Test_ex_equal()
+   new
+   call setline(1, ["foo\tbar", "bar\tfoo"])
+ 
+   let a = execute('=')
+   call assert_equal("\n2", a)
+ 
+   let a = execute('=#')
+   call assert_equal("\n2\n  1 foo     bar", a)
+ 
+   let a = execute('=l')
+   call assert_equal("\n2\nfoo^Ibar$", a)
+ 
+   let a = execute('=p')
+   call assert_equal("\n2\nfoo     bar", a)
+ 
+   let a = execute('=l#')
+   call assert_equal("\n2\n  1 foo^Ibar$", a)
+ 
+   let a = execute('=p#')
+   call assert_equal("\n2\n  1 foo     bar", a)
+ 
+   let a = execute('.=')
+   call assert_equal("\n1", a)
+ 
+   call assert_fails('3=', 'E16:')
+   call assert_fails('=x', 'E488:')
+ 
+   bwipe!
+ endfunc
*** ../vim-8.1.0816/src/version.c	2019-01-24 22:23:55.644948698 +0100
--- src/version.c	2019-01-24 22:41:22.289672995 +0100
***************
*** 789,790 ****
--- 789,792 ----
  {   /* Add new patch number below this line */
+ /**/
+     817,
  /**/

-- 
Not too long ago, unzipping in public was illegal...

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///