Commit a4e06a08 authored by Mathieu Giraud's avatar Mathieu Giraud

Makefile, algo/tests/Makefile: include also stdout/stderr in snapshots

We run should-vdj-to-tap.py unbuffered (python -u) to have the best tee experience.
parent 21a78377
...@@ -17,9 +17,9 @@ static: ...@@ -17,9 +17,9 @@ static:
$(MAKE) all LDFLAGS="-static -static-libstdc++" $(MAKE) all LDFLAGS="-static -static-libstdc++"
test: test:
$(MAKE) COVERAGE="$(COVERAGE)" unit $(MAKE) COVERAGE="$(COVERAGE)" unit 2>&1 | tee algo/tests/out-unit.log
$(MAKE) functional $(MAKE) functional
$(MAKE) test_tools_if_python $(MAKE) test_tools_if_python 2>&1 | tee algo/tests/out-tools.log
@echo @echo
@echo "*** All tests passed. Congratulations !" @echo "*** All tests passed. Congratulations !"
@echo @echo
...@@ -41,8 +41,8 @@ unit: all ...@@ -41,8 +41,8 @@ unit: all
@echo "*** All unit tests passed" @echo "*** All unit tests passed"
functional: all functional: all
$(MAKE) should $(MAKE) should 2>&1 | tee algo/tests/out-should-get.log
$(MAKE) shouldvdj $(MAKE) shouldvdj 2>&1 | tee algo/tests/out-should-vdj.log
should: all should: all
@echo @echo
......
...@@ -14,6 +14,7 @@ SHOULD_VDJ_EXPECTED_FAILS=--expected-fails 84 ...@@ -14,6 +14,7 @@ SHOULD_VDJ_EXPECTED_FAILS=--expected-fails 84
SHOULD_LOCUS_EXPECTED_FAILS=--expected-fails 2 SHOULD_LOCUS_EXPECTED_FAILS=--expected-fails 2
SHOULD_VDJ=$(wildcard should-vdj-tests/*.should-vdj.fa) SHOULD_VDJ=$(wildcard should-vdj-tests/*.should-vdj.fa)
SHOULD_LOCUS=$(wildcard should-vdj-tests/*.should-locus.fa) SHOULD_LOCUS=$(wildcard should-vdj-tests/*.should-locus.fa)
SHOULD_VDJ_TO_TAP=python -u should-vdj-to-tap.py
REPORTS_PATH := $(patsubst %/Makefile,%,$(abspath $(lastword $(MAKEFILE_LIST))))/../../reports REPORTS_PATH := $(patsubst %/Makefile,%,$(abspath $(lastword $(MAKEFILE_LIST))))/../../reports
VALGRIND=valgrind -v --tool=memcheck --leak-check=full --show-reachable=yes --undef-value-errors=yes --track-origins=yes --xml=yes --xml-file="$$(mktemp "$(REPORTS_PATH)/valgrind.xml.XXXXXX")" VALGRIND=valgrind -v --tool=memcheck --leak-check=full --show-reachable=yes --undef-value-errors=yes --track-origins=yes --xml=yes --xml-file="$$(mktemp "$(REPORTS_PATH)/valgrind.xml.XXXXXX")"
...@@ -39,7 +40,7 @@ all: core $(EXEC) ...@@ -39,7 +40,7 @@ all: core $(EXEC)
snapshot: snapshot:
mkdir -p $(SNAPSHOTS_DIR) mkdir -p $(SNAPSHOTS_DIR)
grep . should-get-tests/*.log should-vdj-tests/*.log > $(SNAPSHOT) grep . out-*.log should-get-tests/*.log should-vdj-tests/*.log > $(SNAPSHOT)
touch snapshot-last ; mv snapshot-last snapshot-prev touch snapshot-last ; mv snapshot-last snapshot-prev
ln -s $(SNAPSHOT) snapshot-last ln -s $(SNAPSHOT) snapshot-last
diff -I "20..-..-.." snapshot-prev snapshot-last | diffstat -cC diff -I "20..-..-.." snapshot-prev snapshot-last | diffstat -cC
...@@ -54,19 +55,19 @@ shouldvdj_if_python: ...@@ -54,19 +55,19 @@ shouldvdj_if_python:
shouldlocus_and_vdj: vidjil shouldlocus_and_vdj: vidjil
@echo "*** Launching .should-vdj-fa tests..." @echo "*** Launching .should-vdj-fa tests..."
python should-vdj-to-tap.py -2q -r $(SHOULD_LOCUS_EXPECTED_FAILS) $(SHOULD_VDJ) $(SHOULD_LOCUS) $(SHOULD_VDJ_TO_TAP) -2q -r $(SHOULD_LOCUS_EXPECTED_FAILS) $(SHOULD_VDJ) $(SHOULD_LOCUS)
$(MAKE) shouldvdj_with_rc $(MAKE) shouldvdj_with_rc
@echo "*** All .should-vdj.fa tests passed" @echo "*** All .should-vdj.fa tests passed"
shouldvdj: shouldvdj:
python should-vdj-to-tap.py $(SHOULD_VDJ_EXPECTED_FAILS) $(SHOULD_VDJ) $(SHOULD_VDJ_TO_TAP) $(SHOULD_VDJ_EXPECTED_FAILS) $(SHOULD_VDJ)
shouldvdj_with_rc: shouldvdj_with_rc:
python should-vdj-to-tap.py $(SHOULD_VDJ_EXPECTED_FAILS) -r $(SHOULD_VDJ) $(SHOULD_VDJ_TO_TAP) $(SHOULD_VDJ_EXPECTED_FAILS) -r $(SHOULD_VDJ)
shouldvdj_with_rc_merged: shouldvdj_with_rc_merged:
cat $(SHOULD_VDJ) > should-vdj-tests/should-vdj.merged.fa cat $(SHOULD_VDJ) > should-vdj-tests/should-vdj.merged.fa
python should-vdj-to-tap.py -r should-vdj-tests/should-vdj.merged.fa $(SHOULD_VDJ_TO_TAP) -r should-vdj-tests/should-vdj.merged.fa
curatedvdj_archive: curated-vdj.zip curatedvdj_archive: curated-vdj.zip
curated-vdj.zip: $(SHOULD_VDJ_ARCHIVE) curated-vdj.zip: $(SHOULD_VDJ_ARCHIVE)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment