Adaption to new makefile concetp
This commit is contained in:
parent
631e7c60bf
commit
8b57ebf100
@ -3,32 +3,24 @@ SHELL = /usr/bin/bash
|
||||
.SILENT:
|
||||
|
||||
|
||||
COV3_CMD=venv3/bin/coverage
|
||||
PYT3_CMD=venv3/bin/python
|
||||
COV3_CMD=venv/bin/coverage
|
||||
PYT3_CMD=venv/bin/python
|
||||
PDF_CMD=xdg-open
|
||||
|
||||
OUTDIR=testresults
|
||||
TEXFILE=$(OUTDIR)/unittest.tex
|
||||
PDFFILE=$(OUTDIR)/unittest.pdf
|
||||
|
||||
.PHONY: all help venv3 release full short smoke single testrun_full testrun_short testrun_smoke testrun_single coverage_analysis finalise status compile release_testcases publish view clean
|
||||
|
||||
all: full
|
||||
|
||||
help:
|
||||
echo "make [target]"
|
||||
echo " Here is a list of the most helpfull targets:"
|
||||
echo " - release: Release the testcases, creates a pdf ducument including all testcases and copy testdata to the module"
|
||||
localhelp:
|
||||
echo -e "Possible unittest options are:"
|
||||
echo -e "\033[1;33m - [testrun]_full - Run all testcases and create pdf document, if not a testrun only\e[0m"
|
||||
echo -e "\033[1;33m - [testrun]_short - Run most testcases and create pdf document, if not a testrun only\e[0m"
|
||||
echo -e "\033[1;33m - [testrun]_smoke - Run some fast testcases and create pdf document, if not a testrun only\e[0m"
|
||||
echo -e "\033[1;33m - [testrun]_full - Run a single testcases and create pdf document, if not a testrun only\e[0m"
|
||||
echo " ----------------------------------------------------------------------------------------------------------------"
|
||||
echo " - full: Create a pdf ducument including all testcases"
|
||||
echo " - short: Create a pdf ducument including most testcases"
|
||||
echo " - smoke: Create a pdf ducument including some testcases"
|
||||
echo " - single: Create a pdf ducument including one testcases"
|
||||
echo " ----------------------------------------------------------------------------------------------------------------"
|
||||
echo " - testrun_full: Run all testcases"
|
||||
echo " - testrun_short: Run most testcases"
|
||||
echo " - testrun_smoke: Run some testcases"
|
||||
echo " - testrun_single: Run one testcases"
|
||||
echo -e "\033[1;33m - view - Create a local documentation files and view them\e[0m"
|
||||
echo -e "\033[1;33m - release - Release the testcases, creates a pdf ducument including all testcases and copy testdata to the module\e[0m"
|
||||
|
||||
|
||||
release: testrun_full coverage_analysis finalise compile publish status
|
||||
full: testrun_full finalise compile status
|
||||
@ -36,14 +28,7 @@ short: testrun_short finalise compile status
|
||||
smoke: testrun_smoke finalise compile status
|
||||
single: testrun_single finalise compile status
|
||||
|
||||
init: venv3
|
||||
venv3:
|
||||
echo -e "\033[1;33mCreating virtual env...\e[0m"
|
||||
virtualenv -p /usr/bin/python3 venv3
|
||||
venv3/bin/pip install --upgrade pip
|
||||
venv3/bin/pip install -r requirements.txt
|
||||
|
||||
clean: venv3
|
||||
localclean:
|
||||
echo -e "\033[1;33mCleaning up unittest...\e[0m"
|
||||
echo -e "\e[1m * Testresults from last testrun\e[0m"
|
||||
ls testresults | xargs -i echo " testresults/{}"
|
||||
@ -51,14 +36,10 @@ clean: venv3
|
||||
echo -e "\e[1m * Collected coverage information\e[0m"
|
||||
$(COV3_CMD) erase
|
||||
|
||||
cleanall: clean
|
||||
echo "\e[1m * Virtualenv\e[0m"
|
||||
rm -rf venv3
|
||||
|
||||
release_testcases:
|
||||
$(PYT3_CMD) src/unittest/scripts/unittest.py release_testcases
|
||||
|
||||
prepare: venv3
|
||||
prepare:
|
||||
$(PYT3_CMD) src/unittest/scripts/unittest.py prepare
|
||||
|
||||
testrun_full: clean prepare
|
||||
@ -80,6 +61,7 @@ coverage_analysis:
|
||||
finalise: coverage_analysis
|
||||
$(PYT3_CMD) src/unittest/scripts/unittest.py finalise
|
||||
|
||||
unittest.toc:
|
||||
compile:
|
||||
latexmk -pdf -quiet -pdflatex="pdflatex -interaction=nonstopmode" -output-directory=$(OUTDIR) -use-make $(TEXFILE) > /dev/null
|
||||
|
||||
@ -91,4 +73,3 @@ publish:
|
||||
|
||||
view:
|
||||
$(PDF_CMD) $(PDFFILE)
|
||||
|
Loading…
x
Reference in New Issue
Block a user