diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-06-01 21:32:45 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-06-01 21:32:45 +0200 |
commit | ea6561af92eeb26fa0b4966575da7cadd98af1cd (patch) | |
tree | 29afb0b9c0d3108d9137ea175926ff09b8a892bd /src | |
parent | 5fbf3bc3f9d007ab91eb005f9e3da6570992cb43 (diff) | |
download | vim-git-ea6561af92eeb26fa0b4966575da7cadd98af1cd.tar.gz |
patch 8.2.0884: searchcount() test fails on slower systemsv8.2.0884
Problem: Searchcount() test fails on slower systems.
Solution: Set a longer timeout.
Diffstat (limited to 'src')
-rw-r--r-- | src/search.c | 2 | ||||
-rw-r--r-- | src/testdir/test_search_stat.vim | 8 | ||||
-rw-r--r-- | src/version.c | 2 |
3 files changed, 7 insertions, 5 deletions
diff --git a/src/search.c b/src/search.c index a6b60f63c..0c253e971 100644 --- a/src/search.c +++ b/src/search.c @@ -36,7 +36,7 @@ typedef struct searchstat static void cmdline_search_stat(int dirc, pos_T *pos, pos_T *cursor_pos, int show_top_bot_msg, char_u *msgbuf, int recompute, int maxcount, long timeout); static void update_search_stat(int dirc, pos_T *pos, pos_T *cursor_pos, searchstat_T *stat, int recompute, int maxcount, long timeout); -#define SEARCH_STAT_DEF_TIMEOUT 20L +#define SEARCH_STAT_DEF_TIMEOUT 40L #define SEARCH_STAT_DEF_MAX_COUNT 99 #define SEARCH_STAT_BUF_LEN 12 diff --git a/src/testdir/test_search_stat.vim b/src/testdir/test_search_stat.vim index 7c2a19585..de73051d2 100644 --- a/src/testdir/test_search_stat.vim +++ b/src/testdir/test_search_stat.vim @@ -87,10 +87,10 @@ func Test_search_stat() \ searchcount(#{recompute: 0})) call assert_equal( \ #{current: 272, exact_match: 1, total: 280, incomplete: 0, maxcount: 0}, - \ searchcount(#{recompute: v:true, maxcount: 0})) + \ searchcount(#{recompute: v:true, maxcount: 0, timeout: 200})) call assert_equal( \ #{current: 1, exact_match: 1, total: 280, incomplete: 0, maxcount: 0}, - \ searchcount(#{recompute: 1, maxcount: 0, pos: [1, 1, 0]})) + \ searchcount(#{recompute: 1, maxcount: 0, pos: [1, 1, 0], timeout: 200})) call cursor(line('$'), 1) let g:a = execute(':unsilent :norm! n') let stat = 'W \[1/>99\]' @@ -100,10 +100,10 @@ func Test_search_stat() \ searchcount(#{recompute: 0})) call assert_equal( \ #{current: 1, exact_match: 1, total: 280, incomplete: 0, maxcount: 0}, - \ searchcount(#{recompute: 1, maxcount: 0})) + \ searchcount(#{recompute: 1, maxcount: 0, timeout: 200})) call assert_equal( \ #{current: 271, exact_match: 1, total: 280, incomplete: 0, maxcount: 0}, - \ searchcount(#{recompute: 1, maxcount: 0, pos: [line('$')-2, 1, 0]})) + \ searchcount(#{recompute: 1, maxcount: 0, pos: [line('$')-2, 1, 0], timeout: 200})) " Many matches call cursor(1, 1) diff --git a/src/version.c b/src/version.c index dff6cf922..7931e96ef 100644 --- a/src/version.c +++ b/src/version.c @@ -747,6 +747,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 884, +/**/ 883, /**/ 882, |