Message ID | CANeU7QnXWFad9Re0MtGkei6F6ZnUOH96et5_7aJQommFp2dLwQ@mail.gmail.com (mailing list archive) |
---|---|
State | Rejected, archived |
Headers | show |
On 02/10/14 04:44, Christopher Li wrote: > On Tue, Sep 30, 2014 at 11:26 AM, Christopher Li <sparse@chrisli.org> wrote: >> I am thinking some thing in the test-suite like: >> >> set_deps sparsec sparse-llvm >> set_deps sparsei sparse-llvm >> >> ... >> get_deps `basename cmd` >> dep_cmd=$last_result > > Actually, I try that, it is a little bit too complicated. > > Your first approach is fine. > > I end up using your V1 patch, with a small change to do exact match rather than > a wild cast. The wild cast has danger that match a sub word of the command. > e.g. if you try to disable command "sp", it will disable "sparse" as well. Ah yes, good catch! ATB, Ramsay Jones -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/validation/test-suite b/validation/test-suite index 1c94aa8..784ff6b 100755 --- a/validation/test-suite +++ b/validation/test-suite @@ -111,13 +111,13 @@ do_test() fi # check for disabled commands + set -- $cmd + base_cmd=`basename $1` for i in $disabled_cmds; do - case "$cmd" in - *$i*) + if [ "$i" == "$base_cmd" ] ; then disabled_tests=`expr $disabled_tests + 1` return 3 - ;; - esac + fi done echo " TEST $test_name ($file)"