e511a8b4edf760904d75d7ea803f085f73c39fb0
[platform/upstream/automake.git] / tests / test-missing2.test
1 #! /bin/sh
2 # Copyright (C) 2011-2012 Free Software Foundation, Inc.
3 #
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)
7 # any later version.
8 #
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.
13 #
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/>.
16
17 # parallel-tests:
18 #  - non-existent scripts listed in TESTS get diagnosed, even when
19 #    all the $(TEST_LOGS) have a dummy dependency.
20 # See also related test 'test-missing.test'.
21
22 am_parallel_tests=yes
23 . ./defs || Exit 1
24
25 cat >> configure.ac << 'END'
26 AC_OUTPUT
27 END
28
29 cat > Makefile.am << 'END'
30 TESTS = foobar1.test foobar2.test
31 $(TEST_LOGS):
32 END
33
34 $ACLOCAL
35 $AUTOCONF
36 $AUTOMAKE -a
37
38 ./configure
39
40 $MAKE foobar1.log foobar2.log || Exit 99
41 test ! -f foobar1.log || Exit 99
42 test ! -f foobar1.trs || Exit 99
43 test ! -f foobar2.log || Exit 99
44 test ! -f foobar2.trs || Exit 99
45
46 $MAKE check >output 2>&1 && { cat output; Exit 1; }
47 cat output
48 grep 'test-suite\.log.*foobar1\.log' output
49 grep 'test-suite\.log.*foobar1\.trs' output
50 grep 'test-suite\.log.*foobar2\.log' output
51 grep 'test-suite\.log.*foobar2\.trs' output
52 test ! -f test-suite.log
53
54 :