# HG changeset patch # User Bram Moolenaar # Date 1546978505 -3600 # Node ID f20d90aeecaab959e0b901a1a975fc4a17cd88fb # Parent f5c0980484990f294c41be7f8aa2be93166738c8 patch 8.1.0705: :colorscheme isn't tested enough commit https://github.com/vim/vim/commit/6d4470b0e9aac76ae43be27a28447ea29767d77f Author: Bram Moolenaar Date: Tue Jan 8 21:05:51 2019 +0100 patch 8.1.0705: :colorscheme isn't tested enough Problem: :colorscheme isn't tested enough Solution: Improve test coverage of :colorscheme. (Dominique Pelle, closes #3777) Remove unnecessary sleep. diff --git a/src/testdir/test_gui.vim b/src/testdir/test_gui.vim --- a/src/testdir/test_gui.vim +++ b/src/testdir/test_gui.vim @@ -42,10 +42,15 @@ func Test_colorscheme() colorscheme torte redraw! - sleep 200m call assert_equal('dark', &background) call assert_equal(1, g:before_colors) call assert_equal(2, g:after_colors) + call assert_equal("\ntorte", execute('colorscheme')) + + let a = substitute(execute('hi Search'), "\n\\s\\+", ' ', 'g') + call assert_match("\nSearch xxx term=reverse ctermfg=0 ctermbg=12 gui=bold guifg=Black guibg=Red", a) + + call assert_fails('colorscheme does_not_exist', 'E185:') exec 'colorscheme' colorscheme_saved augroup TestColors diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -800,6 +800,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 705, +/**/ 704, /**/ 703,