diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-09-17 23:03:31 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-09-17 23:03:31 +0200 |
commit | 1b9645de3c05f37b5c30e78f999351b0cf486ade (patch) | |
tree | 4041a73d7fd4ab444372919e99962587a689388a /src/testdir | |
parent | dde403c2d8f3dabe6fefa7b526958b49a8f2e6e9 (diff) |
patch 8.0.1123: cannot define a toolbar for a windowv8.0.1123
Problem: Cannot define a toolbar for a window.
Solution: Add a window-local toolbar.
Diffstat (limited to 'src/testdir')
-rw-r--r-- | src/testdir/Make_all.mak | 5 | ||||
-rw-r--r-- | src/testdir/test_winbar.vim | 23 |
2 files changed, 26 insertions, 2 deletions
diff --git a/src/testdir/Make_all.mak b/src/testdir/Make_all.mak index b979c975b7..169d84fd5d 100644 --- a/src/testdir/Make_all.mak +++ b/src/testdir/Make_all.mak @@ -201,12 +201,13 @@ NEW_TESTS = test_arabic.res \ test_viminfo.res \ test_vimscript.res \ test_visual.res \ + test_winbar.res \ test_window_id.res \ + test_windows_home.res \ test_writefile.res \ test_alot_latin.res \ test_alot_utf8.res \ - test_alot.res \ - test_windows_home.res + test_alot.res # Explicit dependencies. diff --git a/src/testdir/test_winbar.vim b/src/testdir/test_winbar.vim new file mode 100644 index 0000000000..19616073c0 --- /dev/null +++ b/src/testdir/test_winbar.vim @@ -0,0 +1,23 @@ +" Test WinBar + +if !has('menu') + finish +endif + +func Test_add_remove_menu() + new + amenu 1.10 WinBar.Next :let g:did_next = 11<CR> + amenu 1.20 WinBar.Cont :let g:did_cont = 12<CR> + emenu WinBar.Next + call assert_equal(11, g:did_next) + emenu WinBar.Cont + call assert_equal(12, g:did_cont) + + wincmd w + call assert_fails('emenu WinBar.Next', 'E334') + wincmd p + + aunmenu WinBar.Next + aunmenu WinBar.Cont + close +endfunc |