Add startup tester for #25

This commit is contained in:
Andy K. Massimino
2018-04-02 10:27:42 -04:00
parent 91ef9f53b4
commit f387f2324c
2 changed files with 37 additions and 0 deletions

24
test/startup.sh Executable file
View File

@@ -0,0 +1,24 @@
#!/bin/bash
VISUAL=${VISUAL:-vim}
cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd
dir='profile'
mkdir -vp "$dir"
file="$dir/startup-$(date +%Y-%m-%d.%H:%M:%S)"
file1="$file-1.log"
file2="$file-2.log"
"$VISUAL" -u vimrc-startup --startuptime "$file1"
echo 'g:matchup_delim_start_plain=0'
grep matchup "$file1"
export TEST_PLAIN=1
"$VISUAL" -u vimrc-startup --startuptime "$file2"
echo 'g:matchup_delim_start_plain=1'
grep matchup "$file2"

13
test/vimrc-startup Normal file
View File

@@ -0,0 +1,13 @@
set nocompatible
let &rtp = '~/.vim/bundle/vim-matchup,' . &rtp
let &rtp .= ',~/.vim/bundle/vim-matchup/after'
let g:matchup_delim_start_plaintext = !!$TEST_PLAIN
filetype plugin indent on
syntax enable
autocmd BufWinEnter * put!=execute('MatchupShowTimes')|set nomodified
nnoremap q :<c-u>quit<cr>