]> rtime.felk.cvut.cz Git - omk.git/commitdiff
Run tests directly with snippets instead of with the preprocessed rules
authorMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 12 Nov 2013 13:56:08 +0000 (14:56 +0100)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 12 Nov 2013 15:27:53 +0000 (16:27 +0100)
This simplifies debugging failed tests.

tests/Makefile
tests/wvtest.sh

index 93aa1236f78ac979357f754424edf8cc7406b7e6..748b82abeaebfc64c0582ac3213e6d400916d665 100644 (file)
@@ -12,7 +12,6 @@ subdirs_first-force-subdir use_leaf_makefiles vxworks whole_tree omkize
 RULES=$(shell cd ../rules; ls)
 
 all test:
-       $(MAKE) -C ..
        ./wvtestrun $(MAKE) wvtest
 
 ALL_TESTS = $(foreach rule,$(RULES),$(foreach script,$(wvtest_SCRIPTS),$(rule)/$(script)))
index 89e37ec1435db33d5479958ade8723b43b2516ab..cd23e3a319fa7fa042d72a1c02c55d9bf1a35b4c 100644 (file)
@@ -139,6 +139,7 @@ WVSTART()
        mkdir -p "$dir"
        WVPASS cd "$WV_BASE_DIR/$dir"
        WVPASS cp "$OMK_TESTSROOT"/../rules/$OMK_RULES/* .
+       WVPASS cp "$OMK_TESTSROOT"/../snippets/Makefile.rules.$OMK_RULES Makefile.rules
        WVPASS cp "$OMK_TESTSROOT/../leaf-makefile/Makefile" .
 }
 
@@ -192,6 +193,8 @@ testdir="tmp/$(basename $0 .sh).$OMK_RULES"
 WVPASS mkdir -p "$testdir"
 WVPASS cd "$testdir"
 WVPASS cp "$OMK_TESTSROOT"/../rules/$OMK_RULES/* .
+WVPASS cp "$OMK_TESTSROOT"/../snippets/Makefile.rules.$OMK_RULES Makefile.rules
 WVPASS cp "$OMK_TESTSROOT/../leaf-makefile/Makefile" .
 
 WV_BASE_DIR="$PWD"
+export MAKEFLAGS="--include-dir=$OMK_TESTSROOT/../snippets"