Moved function that runs command for all unit tests to unit_test.sh.

Testclean target should work now.
This commit is contained in:
Roman Bovsunivskiy
2010-02-22 17:05:41 +00:00
parent 7b71ab2021
commit c72f02051d
3 changed files with 24 additions and 32 deletions
+3 -31
View File
@@ -7,41 +7,13 @@ SUBDIRS = src doc
DOLLAR = $
build_tests.commands = for directory in `find . -name unit_tests`; \
do \
home=`pwd`; \
echo; \
echo "Building test in "$${DOLLAR}$${DOLLAR}directory; \
cd $${DOLLAR}$${DOLLAR}directory; \
qmake -spec $${DOLLAR}$${DOLLAR}QMAKESPEC; \
make; \
cd $${DOLLAR}$${DOLLAR}home; \
done
build_tests.commands = ./unit_tests.sh make
build_tests.depends = all
run_tests.commands = for directory in `find . -name unit_tests`; \
do \
home=`pwd`; \
echo; \
echo "Running test in "$${DOLLAR}$${DOLLAR}directory; \
cd $${DOLLAR}$${DOLLAR}directory; \
qmake -spec $${DOLLAR}$${DOLLAR}QMAKESPEC; \
make run; \
cd $${DOLLAR}$${DOLLAR}home; \
done
run_tests.commands = ./unit_tests.sh make run
run_tests.depends = all
testclean.commands = for directory in `find . -name unit_tests`; \
do \
home=`pwd`; \
echo; \
echo "Cleaning test files in "$${DOLLAR}$${DOLLAR}directory; \
cd $${DOLLAR}$${DOLLAR}directory; \
qmake -spec $${DOLLAR}$${DOLLAR}QMAKESPEC; \
make clean; \
cd $${DOLLAR}$${DOLLAR}home; \
done
testclean.commands = ./unit_tests.sh make clean
tests.depends = run_tests
QMAKE_EXTRA_TARGETS += build_tests run_tests tests testclean