From a46f2942abbd2b515d7883a5ff3bd9828d241f0f Mon Sep 17 00:00:00 2001 From: Vahagn Khachatryan Date: Sat, 11 Aug 2018 23:01:44 +0100 Subject: [PATCH] test_all target added. --- .vscode/tasks.json | 16 ++++++++++++++++ Makefile | 18 ++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 .vscode/tasks.json diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..f705233 --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,16 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "make test", + "type": "shell", + "command": "make test", + "group": { + "kind": "build", + "isDefault": true + } + } + ] +} \ No newline at end of file diff --git a/Makefile b/Makefile index c549537..1129c2a 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,21 @@ + +TEST_FILES = $(wildcard samples/*.zip) + +.PHONY: test +test: + python gragir/__main__.py -v samples/algorithms_third_edition_in_c.zip algorithms_third_edition_in_c.epub + +.PHONY: test_all +test_all: $(addprefix test_,$(TEST_FILES)) + + +.PHONY: $(addprefix test_,$(TEST_FILES)) +$(addprefix test_,$(TEST_FILES)): test_%: + @echo Testing $* + @python -v gragir/__main__.py $* test_out/$(*F).epub + +#python gragir/__main__.py samples/algorithms_third_edition_in_c.zip algorithms_third_edition_in_c.epub + .PHONY: setup setup: git submodule update