diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/testdir/test_termdebug.vim | 32 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 33 insertions, 1 deletions
diff --git a/src/testdir/test_termdebug.vim b/src/testdir/test_termdebug.vim index a9762df8a2..d3bf5f489c 100644 --- a/src/testdir/test_termdebug.vim +++ b/src/testdir/test_termdebug.vim @@ -297,6 +297,9 @@ func Test_termdebug_mapping() call assert_true(maparg('+', 'n', 0, 1).buffer) call assert_equal(':echom "bK"<cr>', maparg('K', 'n', 0, 1).rhs) + nunmap K + nunmap + + nunmap - %bw! endfunc @@ -339,14 +342,41 @@ func Test_termdebug_bufnames() endfunc function Test_termdebug_save_restore_variables() + " saved mousemodel let &mousemodel='' + + " saved keys + nnoremap K :echo "hello world!"<cr> + let expected_map_K = maparg('K', 'n', 0 , 1) + nnoremap + :echo "hello plus!"<cr> + let expected_map_plus = maparg('+', 'n', 0 , 1) + let expected_map_minus = {} + + " saved &columns + let expected_columns = &columns + + " We want termdebug to overwrite 'K' map but not '+' map. + let g:termdebug_config = {} + let g:termdebug_config['map_K'] = 1 + Termdebug call WaitForAssert({-> assert_equal(3, winnr('$'))}) call WaitForAssert({-> assert_match(&mousemodel, 'popup_setpos')}) wincmd t quit! call WaitForAssert({-> assert_equal(1, winnr('$'))}) - call WaitForAssert({-> assert_true(empty(&mousemodel))}) + + call assert_true(empty(&mousemodel)) + + call assert_true(empty(expected_map_minus)) + call assert_equal(expected_map_K.rhs, maparg('K', 'n', 0, 1).rhs) + call assert_equal(expected_map_plus.rhs, maparg('+', 'n', 0, 1).rhs) + + call assert_equal(expected_columns, &columns) + + nunmap K + nunmap + + unlet g:termdebug_config endfunction diff --git a/src/version.c b/src/version.c index 14a5922a99..8174104768 100644 --- a/src/version.c +++ b/src/version.c @@ -705,6 +705,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 497, +/**/ 496, /**/ 495, |