Skip to content

Commit 56e6bd7

Browse files
committed
patch 8.0.0277: the GUI test may trigger fontconfig and take a long time
Problem: The GUI test may trigger fontconfig and take a long time. Solution: Set $XDG_CACHE_HOME. (Kazunobu Kuriyama)
1 parent 3954e3c commit 56e6bd7

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

src/testdir/test_gui.vim

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ func SetUp()
1010
set guifont=Courier\ 10\ Pitch/8/-1/5/50/0/0/0/0/0
1111
endif
1212

13-
" Gnome insists on creating $HOME/.gnome2/..
13+
" Gnome insists on creating $HOME/.gnome2/, and we're going to abide by
14+
" that, taking care to have the font cache work normally.
15+
if $XDG_CACHE_HOME == ''
16+
let $XDG_CACHE_HOME = g:tester_HOME . '/.cache'
17+
endif
1418
call mkdir('Xhome')
1519
let $HOME = fnamemodify('Xhome', ':p')
1620
endfunc

src/testdir/unix.vim

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,9 @@
22
" Always use "sh", don't use the value of "$SHELL".
33
set shell=sh
44

5+
" While some tests overwrite $HOME to prevent them from polluting user files,
6+
" we need to remember the original value so that we can tell external systems
7+
" where to ask about their own user settings.
8+
let g:tester_HOME = $HOME
9+
510
source setup.vim

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,8 @@ static char *(features[]) =
764764

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
277,
767769
/**/
768770
276,
769771
/**/

0 commit comments

Comments
 (0)