test/test_protocol: make pretty(-ish) SVG diagrams.

Could make them much prettier, but they're functional.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2016-05-17 15:02:08 +09:30
parent 126c91e1b1
commit 06d2c19c41
2 changed files with 264 additions and 36 deletions

View File

@@ -216,6 +216,11 @@ test-onion4: test/test_onion test/onion_key
test-protocol: test/test_protocol
set -e; TMP=`mktemp`; [ -n "$(NO_VALGRIND)" ] || PREFIX="valgrind -q --error-exitcode=7"; for f in test/commits/*.script; do if ! $$PREFIX test/test_protocol < $$f > $$TMP; then echo "test/test_protocol < $$f FAILED" >&2; exit 1; fi; diff -u $$TMP $$f.expected; done; rm $$TMP
doc/protocol-%.svg: test/test_protocol
test/test_protocol --svg < test/commits/$*.script > $@
protocol-diagrams: $(patsubst %.script, doc/protocol-%.svg, $(notdir $(wildcard test/commits/*.script)))
check: daemon-tests test-onion test-protocol bitcoin-tests
include bitcoin/Makefile