blob: 143665357a32388fda6222dc6db0dcbdfc11b5a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
#!/usr/bin/env bash
REPO_TOP=$(git rev-parse --show-toplevel)
cd "${REPO_TOP}"
echo "Check for Vader"
echo "---------------"
vim -Nu <(cat <<EOF
function! s:chk_vader_exists()
if exists(":Vader")
cquit 0
else
echom 'Vader not found. Please install it.'
echom 'https://github.com/junegunn/vader.vim'
cquit 1
endif
endfunction
command! ChkVaderExists call s:chk_vader_exists()
EOF
) '+ChkVaderExists' || exit 1
echo "Basic environment"
echo "-----------------"
vim -Nu <(cat <<EOF
filetype off
set rtp+=~/.vim/bundle/vader.vim
set rtp+=./
filetype plugin indent on
syntax enable
autocmd filetype todo setlocal omnifunc=todo#Complete
EOF
) +Vader! tests/*.vader && echo Success || exit 1
# Run through variations of user preferences that might mess with us.
echo
echo "Ignore case enabled"
echo "-------------------"
vim -Nu <(cat <<EOF
filetype off
set rtp+=~/.vim/bundle/vader.vim
set rtp+=./
filetype plugin indent on
syntax enable
autocmd filetype todo setlocal omnifunc=todo#Complete
set ignorecase
EOF
) +Vader! tests/*.vader && echo Success || exit 1
echo
echo "no hyphen in iskeyword"
echo "----------------------"
vim -Nu <(cat <<EOF
filetype off
set rtp+=~/.vim/bundle/vader.vim
set rtp+=./
filetype plugin indent on
syntax enable
autocmd filetype todo setlocal omnifunc=todo#Complete
set iskeyword+=-
EOF
) +Vader! tests/*.vader && echo Success || exit 1
echo
echo "All tests are passing."
echo
|