Mercurial > vim
diff src/testdir/test_filetype.vim @ 28483:62a0dd56466c v8.2.4766
patch 8.2.4766: KRL files using "deffct" not recognized
Commit: https://github.com/vim/vim/commit/93c7a45e86934a92ec513b437fe9b8cc343c53e3
Author: KnoP-01 <knosowski@graeffrobotics.de>
Date: Sat Apr 16 21:14:04 2022 +0100
patch 8.2.4766: KRL files using "deffct" not recognized
Problem: KRL files using "deffct" not recognized.
Solution: Adjust the pattern used for matching. (Patrick Meiser-Knosowski,
closes #10200)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 16 Apr 2022 22:15:03 +0200 |
parents | 7f0ec490d608 |
children | 75f181bef230 |
line wrap: on
line diff
--- a/src/testdir/test_filetype.vim +++ b/src/testdir/test_filetype.vim @@ -768,7 +768,7 @@ func Test_filetype_indent_off() endfunc """"""""""""""""""""""""""""""""""""""""""""""""" -" Tests for specific extentions and filetypes. +" Tests for specific extensions and filetypes. " Keep sorted. """"""""""""""""""""""""""""""""""""""""""""""""" @@ -1562,11 +1562,13 @@ func Test_src_file() bwipe! call delete('srcfile.Src') - " KRL global def with embedded spaces, file starts with empty line(s). - call writefile(['', 'global def srcfile()'], 'srcfile.SRC') - split srcfile.SRC - call assert_equal('krl', &filetype) - bwipe! + " KRL global deffct with embedded spaces, file starts with empty line(s). + for text in ['global def srcfile()', 'global deffct srcfile()'] + call writefile(['', text], 'srcfile.SRC') + split srcfile.SRC + call assert_equal('krl', &filetype, text) + bwipe! + endfor " User may overrule file inspection let g:filetype_src = 'src'