comparison src/testdir/test_behave.vim @ 14754:d4db9adc8642 v8.1.0389

patch 8.1.0389: :behave command is not tested commit https://github.com/vim/vim/commit/da1f71d75f0bf5d5ef876a09aa08fb19f6f24b3b Author: Bram Moolenaar <Bram@vim.org> Date: Fri Sep 14 20:10:32 2018 +0200 patch 8.1.0389: :behave command is not tested Problem: :behave command is not tested. Solution: Add a test. (Dominique Pelle, closes https://github.com/vim/vim/issues/3429)
author Christian Brabandt <cb@256bit.org>
date Fri, 14 Sep 2018 20:15:05 +0200
parents
children 08940efa6b4e
comparison
equal deleted inserted replaced
14753:cb742b188eea 14754:d4db9adc8642
1 " Test the :behave command
2
3 func Test_behave()
4 behave mswin
5 call assert_equal('mouse,key', &selectmode)
6 call assert_equal('popup', &mousemodel)
7 call assert_equal('startsel,stopsel', &keymodel)
8 call assert_equal('exclusive', &selection)
9
10 behave xterm
11 call assert_equal('', &selectmode)
12 call assert_equal('extend', &mousemodel)
13 call assert_equal('', &keymodel)
14 call assert_equal('inclusive', &selection)
15
16 set selection&
17 set mousemodel&
18 set keymodel&
19 set selection&
20 endfunc
21
22 func Test_behave_completion()
23 call feedkeys(":behave \<C-A>\<C-B>\"\<CR>", 'tx')
24 call assert_equal('"behave mswin xterm', @:)
25 endfunc
26
27 func Test_behave_error()
28 call assert_fails('behave x', 'E475:')
29 endfunc