summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-02-04 21:53:33 +0100
committerBram Moolenaar <Bram@vim.org>2016-02-04 21:53:33 +0100
commit3fc3e14282c182c046d1335f3d576bc0eeb605c5 (patch)
tree9ef432d48026b66e8f451215775ed79029d2d4fc
parenta02b321686d9827ac806353ea8af780676da340d (diff)
downloadvim-git-3fc3e14282c182c046d1335f3d576bc0eeb605c5.tar.gz
patch 7.4.1259v7.4.1259
Problem: No test for what patch 7.3.414 fixed. Solution: Add a test. (Elias Diem)
-rw-r--r--src/testdir/test_increment.vim19
-rw-r--r--src/version.c2
2 files changed, 21 insertions, 0 deletions
diff --git a/src/testdir/test_increment.vim b/src/testdir/test_increment.vim
index 9b592edce..275969e15 100644
--- a/src/testdir/test_increment.vim
+++ b/src/testdir/test_increment.vim
@@ -708,4 +708,23 @@ func Test_visual_increment_38()
call assert_equal([0, 1, 2, 0], getpos('.'))
endfunc
+" Test what patch 7.3.414 fixed. Ctrl-A on "000" drops the leading zeros.
+func Test_normal_increment_01()
+ call setline(1, "000")
+ exec "norm! gg0\<C-A>"
+ call assert_equal("001", getline(1))
+
+ call setline(1, "000")
+ exec "norm! gg$\<C-A>"
+ call assert_equal("001", getline(1))
+
+ call setline(1, "001")
+ exec "norm! gg0\<C-A>"
+ call assert_equal("002", getline(1))
+
+ call setline(1, "001")
+ exec "norm! gg$\<C-A>"
+ call assert_equal("002", getline(1))
+endfunc
+
" vim: tabstop=2 shiftwidth=2 expandtab
diff --git a/src/version.c b/src/version.c
index dfed7c2b5..634b97c23 100644
--- a/src/version.c
+++ b/src/version.c
@@ -743,6 +743,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1259,
+/**/
1258,
/**/
1257,