diff --git a/.gitignore b/.gitignore index 5338046..fd69248 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,6 @@ vimball.txt *.orig tags +test/build +test/*.tap +test/*.msgout diff --git a/Makefile b/Makefile index 575c5c1..67b2168 100644 --- a/Makefile +++ b/Makefile @@ -47,7 +47,7 @@ version: $(DOC) test: - runVimTests -0 test + $(MAKE) -C test install: $(SOURCES) for dir in $(^D);\ diff --git a/test/Makefile b/test/Makefile new file mode 100644 index 0000000..62f57dd --- /dev/null +++ b/test/Makefile @@ -0,0 +1,9 @@ +all: build/runVimTests + build/runVimTests/bin/runVimTests.sh -0 . + +build/runVimTests: build/VimTAP + git clone https://github.com/inkarkat/runVimTests $@ + +# Use VimTAP as directory name, as used with runVimTestsSetup.vim. +build/VimTAP: + git clone https://github.com/inkarkat/vimtap $@ diff --git a/test/README b/test/README deleted file mode 100644 index 21b3cea..0000000 --- a/test/README +++ /dev/null @@ -1,13 +0,0 @@ -The plugins runVimTests (http://www.vim.org/scripts/script.php?script_id=2565) -and VimTAP (http://www.vim.org/scripts/script.php?script_id=2213) are needed to -run these tests. - -Besides the _setup.vim configuration file present in this repo you need to -create a global one and place it in the same dir where the runVimTests -executable is located. Assuming the executable is at '~/bin/runVimTests' this -global configuration file should be '~/bin/runVimTestsSetup.vim' and should -have something like the following lines inside of it: - -" Prepend tests repos to &rtp -let &runtimepath = '/path/to/runVimTests_dir,' . &rtp -let &runtimepath = '/path/to/vimTAP_dir,' . &rtp diff --git a/test/README.md b/test/README.md new file mode 100644 index 0000000..55a3990 --- /dev/null +++ b/test/README.md @@ -0,0 +1,18 @@ +# Automatic test setup +You can use `make` (or `make test` from the top level directory) to run the +tests. + +# Manual test setup instructions +The plugins [runVimTests](http://www.vim.org/scripts/script.php?script_id=2565) +and [VimTAP](http://www.vim.org/scripts/script.php?script_id=2213) are needed +to run these tests. + +Besides the `_setup.vim` configuration file present in this repo you need to +create a global one and place it in the same dir where the runVimTests +executable is located. Assuming the executable is at '~/bin/runVimTests' this +global configuration file should be '~/bin/runVimTestsSetup.vim' and should +have something like the following lines inside of it: + + " Prepend tests repos to &rtp + let &runtimepath = '/path/to/runVimTests_dir,' . &rtp + let &runtimepath = '/path/to/vimTAP_dir,' . &rtp