Mercurial > vim
changeset 17532:24d7a7d27471 v8.1.1764
patch 8.1.1764: ":browse oldfiles" is not tested
commit https://github.com/vim/vim/commit/5328cb8986d2620f45b41acf28778f8ce2f8cac1
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Jul 27 23:27:51 2019 +0200
patch 8.1.1764: ":browse oldfiles" is not tested
Problem: ":browse oldfiles" is not tested.
Solution: Add a test.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 27 Jul 2019 23:30:04 +0200 |
parents | 3a6150469ecb |
children | 5ab1c0b8224d |
files | src/testdir/test_viminfo.vim src/version.c |
diffstat | 2 files changed, 8 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/testdir/test_viminfo.vim +++ b/src/testdir/test_viminfo.vim @@ -537,4 +537,10 @@ func Test_viminfo_oldfiles() call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt', '3: /tmp/another.txt'], filter(split(execute('oldfiles'), "\n"), {i, v -> v =~ '/tmp/'})) call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt'], filter(split(execute('filter file_ oldfiles'), "\n"), {i, v -> v =~ '/tmp/'})) call assert_equal(['3: /tmp/another.txt'], filter(split(execute('filter /another/ oldfiles'), "\n"), {i, v -> v =~ '/tmp/'})) + + new + call feedkeys("3\<CR>", 't') + browse oldfiles + call assert_equal("/tmp/another.txt", expand("%")) + bwipe endfunc