Mercurial > vim
diff src/testdir/test_spell.vim @ 20802:ed00f0fbdaef v8.2.0953
patch 8.2.0953: spell checking doesn't work for CamelCased words
Commit: https://github.com/vim/vim/commit/362b44bd4aa87a2aef0f8fd5a28d68dd09a7d909
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Jun 10 21:47:00 2020 +0200
patch 8.2.0953: spell checking doesn't work for CamelCased words
Problem: Spell checking doesn't work for CamelCased words.
Solution: Add the "camel" value in the new option 'spelloptions'.
(closes #1235)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 10 Jun 2020 22:00:04 +0200 |
parents | 88d71b6fbae0 |
children | 6a4806e326dd |
line wrap: on
line diff
--- a/src/testdir/test_spell.vim +++ b/src/testdir/test_spell.vim @@ -77,6 +77,11 @@ func Test_spellbadword() call assert_equal(['bycycle', 'bad'], spellbadword('My bycycle.')) call assert_equal(['another', 'caps'], 'A sentence. another sentence'->spellbadword()) + call assert_equal(['TheCamelWord', 'bad'], 'TheCamelWord asdf'->spellbadword()) + set spelloptions=camel + call assert_equal(['asdf', 'bad'], 'TheCamelWord asdf'->spellbadword()) + set spelloptions= + set spelllang=en call assert_equal(['', ''], spellbadword('centre')) call assert_equal(['', ''], spellbadword('center'))