diff options
author | Bram Moolenaar <Bram@vim.org> | 2016-08-14 19:08:45 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2016-08-14 19:08:45 +0200 |
commit | e59215c7dcae17b03daf39517560cfaa03314f5a (patch) | |
tree | 6c0a732a4d16d50668db89ea7d5a8f2cd8d35884 /src/testdir/test_viminfo.vim | |
parent | e56132bb4167f8b6ea4814cc2c99a71df3d07ff8 (diff) | |
download | vim-git-e59215c7dcae17b03daf39517560cfaa03314f5a.tar.gz |
patch 7.4.2212v7.4.2212
Problem: Mark " is not set when closing a window in another tab. (Guraga)
Solution: Check all tabs for the window to be valid. (based on patch by
Hirohito Higashi, closes #974)
Diffstat (limited to 'src/testdir/test_viminfo.vim')
-rw-r--r-- | src/testdir/test_viminfo.vim | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/testdir/test_viminfo.vim b/src/testdir/test_viminfo.vim index 4c4935b92..cbe481c59 100644 --- a/src/testdir/test_viminfo.vim +++ b/src/testdir/test_viminfo.vim @@ -425,3 +425,33 @@ func Test_viminfo_file_marks() call delete('Xviminfo') endfunc + +func Test_viminfo_file_mark_tabclose() + tabnew Xtestfileintab + call setline(1, ['a','b','c','d','e']) + 4 + q! + wviminfo Xviminfo + sp Xviminfo + /^> .*Xtestfileintab + let lnum = line('.') + while 1 + if lnum == line('$') + call assert_false(1, 'mark not found in Xtestfileintab') + break + endif + let lnum += 1 + let line = getline(lnum) + if line == '' + call assert_false(1, 'mark not found in Xtestfileintab') + break + endif + if line =~ "^\t\"" + call assert_equal('4', substitute(line, ".*\"\t\\(\\d\\).*", '\1', '')) + break + endif + endwhile + + call delete('Xviminfo') + silent! bwipe Xtestfileintab +endfunc |