Test new test framework
This commit is contained in:
parent
6f2b869b0c
commit
e58a94802a
3 changed files with 27 additions and 10 deletions
5
other/rc.vim
Normal file
5
other/rc.vim
Normal file
|
|
@ -0,0 +1,5 @@
|
||||||
|
filetype off
|
||||||
|
set rtp+=./plugins/vader.vim
|
||||||
|
set rtp+=./plugins/nvim-nim
|
||||||
|
filetype plugin indent on
|
||||||
|
syntax enable
|
||||||
|
|
@ -1,11 +1,14 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
export NVIM_LISTEN_ADDRESS="/tmp/nvim"
|
|
||||||
nvim --headless&
|
# Intall plugins
|
||||||
nvimpid=$!
|
mkdir plugins
|
||||||
sleep 2
|
git clone https://github.com/baabelfish/vader.vim plugins/vader.vim
|
||||||
sh -c "py.test -v tests/vim/**.py"
|
git clone https://github.com/baabelfish/nvim-nim plugins/nvim-nim
|
||||||
haderr=$?
|
|
||||||
sleep 1
|
# Run tests
|
||||||
kill $nvimpid
|
nvim -u rc.vim -c 'Vader! tests/**/*.vader'
|
||||||
wait
|
err=$?
|
||||||
exit $haderr
|
if [ "$err" != "0" ]; then
|
||||||
|
cat report.log
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
|
||||||
9
other/tests/vim/smoke.vader
Normal file
9
other/tests/vim/smoke.vader
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
Do (file):
|
||||||
|
ifoo\<esc>
|
||||||
|
|
||||||
|
Expect (else):
|
||||||
|
foo
|
||||||
|
|
||||||
|
|
||||||
|
Execute (something):
|
||||||
|
AssertEqual 1, 2
|
||||||
Loading…
Add table
Add a link
Reference in a new issue