comparison src/testdir/test_regexp_latin.vim @ 19249:2a017e9dc6da v8.2.0183

patch 8.2.0183: tests fail when the float feature is disabled Commit: https://github.com/vim/vim/commit/5feabe00c47fa66d5f4c95213f150488433f78e3 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jan 30 18:24:53 2020 +0100 patch 8.2.0183: tests fail when the float feature is disabled Problem: Tests fail when the float feature is disabled. Solution: Skip tests that don't work without float support.
author Bram Moolenaar <Bram@vim.org>
date Thu, 30 Jan 2020 18:30:04 +0100
parents ad9e9e92ad55
children 0b42b5e50344
comparison
equal deleted inserted replaced
19248:5e803caf5e9c 19249:2a017e9dc6da
1 " Tests for regexp in latin1 encoding 1 " Tests for regexp in latin1 encoding
2 set encoding=latin1 2 set encoding=latin1
3 scriptencoding latin1 3 scriptencoding latin1
4
5 source check.vim
4 6
5 func s:equivalence_test() 7 func s:equivalence_test()
6 let str = "AÀÁÂÃÄÅ B C D EÈÉÊË F G H IÌÍÎÏ J K L M NÑ OÒÓÔÕÖØ P Q R S T UÙÚÛÜ V W X YÝ Z aàáâãäå b c d eèéêë f g h iìíîï j k l m nñ oòóôõöø p q r s t uùúûü v w x yýÿ z" 8 let str = "AÀÁÂÃÄÅ B C D EÈÉÊË F G H IÌÍÎÏ J K L M NÑ OÒÓÔÕÖØ P Q R S T UÙÚÛÜ V W X YÝ Z aàáâãäå b c d eèéêë f g h iìíîï j k l m nñ oòóôõöø p q r s t uùúûü v w x yýÿ z"
7 let groups = split(str) 9 let groups = split(str)
8 for group1 in groups 10 for group1 in groups
130 call assert_equal(0, search("[ -*\\t-\\n]")) 132 call assert_equal(0, search("[ -*\\t-\\n]"))
131 bwipe! 133 bwipe!
132 endfunc 134 endfunc
133 135
134 func Test_pattern_compile_speed() 136 func Test_pattern_compile_speed()
135 if !exists('+spellcapcheck') || !has('reltime') 137 CheckOption spellcapcheck
136 return 138 CheckFunction reltimefloat
137 endif 139
138 let start = reltime() 140 let start = reltime()
139 " this used to be very slow, not it should be about a second 141 " this used to be very slow, not it should be about a second
140 set spc=\\v(((((Nxxxxxxx&&xxxx){179})+)+)+){179} 142 set spc=\\v(((((Nxxxxxxx&&xxxx){179})+)+)+){179}
141 call assert_inrange(0.01, 10.0, reltimefloat(reltime(start))) 143 call assert_inrange(0.01, 10.0, reltimefloat(reltime(start)))
142 set spc= 144 set spc=