Skip to content

Commit 5c3a719

Browse files
author
Adriaan Zonnenberg
committed
Simplify testing commands using a Makefile
1 parent a0cfe67 commit 5c3a719

File tree

5 files changed

+34
-65
lines changed

5 files changed

+34
-65
lines changed

Makefile

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
test: dependencies
2+
vim -u test/vimrc -c 'Vader! test/*.vader'
3+
4+
test-nvim: dependencies
5+
VADER_OUTPUT_FILE=/dev/stderr nvim -u test/vimrc -c 'Vader! test/*.vader' --headless
6+
7+
dependencies = \
8+
'junegunn/vader.vim' \
9+
'cakebaker/scss-syntax.vim' \
10+
'digitaltoad/vim-pug' \
11+
'groenewege/vim-less' \
12+
'kchmck/vim-coffee-script' \
13+
'leafgarland/typescript-vim' \
14+
'slm-lang/vim-slm' \
15+
'wavded/vim-stylus' \
16+
'scrooloose/nerdcommenter'
17+
18+
dependencies:
19+
test -L pack/testing/start/vim-vue && exit 0; \
20+
mkdir -p pack/testing/start; \
21+
cd pack/testing/start; \
22+
for repo in $(dependencies); do git clone https://github.com/$$repo.git; done; \
23+
ln -s ../../.. vim-vue
24+
25+
clean:
26+
rm -rf pack
27+
28+
.PHONY: test test-nvim dependencies clean

circle.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ dependencies:
33
- sudo add-apt-repository ppa:jonathonf/vim -y
44
- sudo apt-get update
55
- sudo apt-get install vim
6-
- bash test/install.sh
6+
- make dependencies
77

88
test:
99
override:
10-
- vim -u test/vimrc -c 'Vader! test/*.vader'
10+
- make test

readme.md

+4
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ npm i -g eslint eslint-plugin-vue
4545
If your language is not getting highlighted open an issue or a PR with the fix.
4646
You only need to add a line to the `syntax/vue.vim` file.
4747

48+
Don't forget to write [Vader](https://github.com/junegunn/vader.vim) tests for
49+
the code you write. You can run the tests by executing `make test` in the
50+
terminal.
51+
4852
## FAQ
4953

5054
### Where is Jade?

test/install.sh

-31
This file was deleted.

test/readme.md

-32
This file was deleted.

0 commit comments

Comments
 (0)