tests: give few aclocal tests more significant names
[automake.git] / t / txinfo20.sh
blob261725d8ed5826709925e7bd77c39bbc5a6f6bd1
1 #! /bin/sh
2 # Copyright (C) 2003-2012 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)
7 # any later version.
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 # Make sure info files survive makeinfo errors.
19 required=makeinfo
20 . test-init.sh
22 echo AC_OUTPUT >> configure.ac
24 cat > Makefile.am << 'END'
25 info_TEXINFOS = main.texi sub/main.texi
26 END
28 mkdir sub
30 cat > main.texi << 'END'
31 \input texinfo
32 @setfilename main
33 @settitle main
34 @node Top
35 Hello walls.
36 @bye
37 END
39 cp main.texi sub/main.texi
41 $ACLOCAL
42 $AUTOMAKE --add-missing
43 $AUTOCONF
45 ./configure
46 $MAKE
48 # Feign more info files.
49 : > main-1
50 : > sub/main-1
52 # Break main.texi.
53 $sleep
54 cp main.texi main.old
55 cat > main.texi << 'END'
56 \input texinfo
57 @setfilename main
58 @settitle main
59 @node Top
60 @unknown_macro{Hello walls.}
61 @bye
62 END
64 # makeinfo will bail out, but we should conserve the old info files.
65 $MAKE && exit 1
66 test -f main
67 test -f main-1
69 # Restore main.texi, and break sub/main.texi.
70 cp main.texi sub/main.texi
71 mv main.old main.texi
72 $MAKE && exit 1
73 test -f main
74 test ! -e main-1
75 test -f sub/main
76 test -f sub/main-1