'make perf': New target.

This commit is contained in:
Daniel Shahaf 2015-10-27 09:46:51 +02:00
parent 9816fcf055
commit 4513eaea71
2 changed files with 15 additions and 0 deletions

View file

@ -29,4 +29,15 @@ test:
done | $(ZSH) -f tests/tap-colorizer.zsh; \
exit $$result
perf:
@result=0; \
for test in highlighters/*; do \
if [ -d $$test/test-data ]; then \
echo "Running test $${test##*/}"; \
$(ZSH) -f tests/test-perfs.zsh "$${test##*/}"; \
: $$(( result |= $$? )); \
fi \
done; \
exit $$result
.PHONY: all install test

View file

@ -32,3 +32,7 @@ performance test
[`test-perfs.zsh`](tests/test-perfs.zsh) measures the time spent doing the highlighting. Usage:
zsh test-perfs.zsh <HIGHLIGHTER NAME>
All tests may be run with
make perf