2 # Copyright (C) 2009-2017 Free Software Foundation, Inc.
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2, or (at your option)
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program. If not, see <http://www.gnu.org/licenses/>.
17 # Check parallel-tests features:
18 # - per-extension "test runners" a.k.a. "log compilers" (xxx_LOG_COMPILER
19 # and xxx_LOG_FLAGS), when some tests are PROGRAMS.
20 # See also related test 'parallel-tests-log-compiler-1.sh'.
25 cat >> configure.ac
<< 'END'
30 cat > Makefile.am
<< 'END'
31 ## Note that automake should not match the '/test' part
32 ## of 'sub/test' as '.test' suffix.
33 TESTS
= foo.chk bar.
test $
(check_PROGRAMS
) sub
/test
34 check_PROGRAMS
= baz bla.
test bli.suff
35 TEST_EXTENSIONS
= .chk .
test
36 CHK_LOG_COMPILER
= .
/chk-compiler
37 TEST_LOG_COMPILER
= .
/test-compiler
38 LOG_COMPILER
= .
/noext-compiler
49 cat >chk-compiler
<<'END'
57 chmod a
+x chk-compiler
58 cp chk-compiler test-compiler
59 cp chk-compiler noext-compiler
85 $MAKE check ||
{ cat test-suite.log
; exit 1; }
88 grep 'chk-compiler *1 *2' foo.log
89 grep 'test-compiler *3 *4' bar.log
90 grep 'noext-compiler *5 *6' baz.log
91 grep 'test-compiler *3 *4' bla.log
92 grep 'noext-compiler *5 *6' bli.suff.log
93 grep 'noext-compiler *5 *6' sub
/test.log