1b16720b7b
- Less code, Easyer to maintain, to add a markup language - Faster to load, and to highlight - Support multiline tags: #847 - Support nested tags - Support intraword tags: this<b>bold</b>type #640 |
||
---|---|---|
.. | ||
independent_runs | ||
resources | ||
command_generate_links.vader | ||
command_generate_tags.vader | ||
command_goto.vader | ||
command_rename_link.vader | ||
command_toc.vader | ||
commentstring.vader | ||
convert_default_html.vader | ||
diary_rss_feed.vader | ||
html_blockquote.vader | ||
issue_markdown.vader | ||
link_creation.vader | ||
link_markdown_multiple_per_file.vader | ||
list_clean.vader | ||
list_margin.vader | ||
list_todo.vader | ||
list_update.vader | ||
list_VimwikiReturn.vader | ||
README.md | ||
run_tests.sh | ||
syntax.vader | ||
table_autoformat.vader | ||
tabnext_delay.vader | ||
vimrc | ||
z_success.vader |
Vimwiki Tests
This directory contains a test framework used to automatically test/verify Vimwiki functionality. It is based on the following tools:
Resources
- Vim patches
- Example test cases:
Building Docker Image
To build the Docker image run docker build -t vimwiki .
from the Vimwiki
repository root (same location as the Dockerfile).
Running Tests
Manual Steps
Starting in the test directory run this command:
docker run -it --rm -v $PWD/../:/testplugin -v $PWD/../test:/home vimwiki vim_7.4.1099 -u test/vimrc -i NONE
This will open a vim instance in the docker container and then all tests
can be run with :Vader test/*
or individual tests can be run.
Note: Substitute vim_7.4.1099
for any of the vim versions in the Dockerfile.
Automated Tests
The script in the test/
directory named run_test.sh
can be used to
automatically run all tests for all installed vim versions. The vim/nvim
versions are parsed from the Dockerfile. This script will also run Vint
for all
plugin source files. For more information run ./run_tests.sh -h
.
Writing Tests
You are advice to write tests at the top of the file where you want to include it because some Execute
can have some side effect making it hard to debug
Inside the container
$USER
->vimtest
: unprivileged => very hard to mess up things$HOME
->/home/vimtest
: but it is readonly !$PWD
->/testplugin
: mapped to vimwiki plugin root directory
For more information, read the base docker image
Known Issues
- neovim v0.2.x does not work correctly with Vader output from the docker
container. No test results are printed and an error message saying
Vim: Error reading input, exiting...
- Probably need to look into this more and determine if the issue is Vader, Neovim, or Docker.
- Vader does not play nice with the location list. Tests that use the location
list should be placed in
independent_runs/
.
Notable Vim patches
v7.3.831
getbufvar
added a default valuev7.4.236
add ability to check patch with has("patch-7.4.123")v7.4.279
added the option to forglobpath()
to return a listv7.4.1546
sticky type checking removed (allow a variables type to change)v7.4.1989
filter()
accepts a Funcrefv7.4.2044
lambda support added - see:h expr-lambda
v7.4.2120
Added function "closure" argumentv7.4.2137
addfuncref()
v8.0
async jobs and timers