tests: texinfo unrecognized extensions
authorStefano Lattarini <stefano.lattarini@gmail.com>
Tue, 11 Jan 2011 01:20:19 +0000 (02:20 +0100)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Tue, 11 Jan 2011 01:20:57 +0000 (02:20 +0100)
* tests/txinfo-unrecognized-extension.test: New test.
* tests/Makefile.am (TESTS): Update.

ChangeLog
tests/Makefile.am
tests/Makefile.in
tests/txinfo-unrecognized-extension.test [new file with mode: 0755]

index 1d69f4b..57c4241 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2011-01-11  Stefano Lattarini  <stefano.lattarini@gmail.com>
 
+       tests: texinfo unrecognized extensions
+       * tests/txinfo-unrecognized-extension.test: New test.
+       * tests/Makefile.am (TESTS): Update.
+
        Improve, extend and tweak tests on Texinfo support.
        * tests/instdir-texi.test: Add a call to `ls -l' after that to
        `make', for debugging.  When looking for required tools, do not
index ed42398..5fcb616 100644 (file)
@@ -903,6 +903,7 @@ txinfo30.test \
 txinfo31.test \
 txinfo32.test \
 txinfo33.test \
+txinfo-unrecognized-extension.test \
 transform.test \
 transform2.test \
 unused.test \
index 84abf4d..591bc19 100644 (file)
@@ -1166,6 +1166,7 @@ txinfo30.test \
 txinfo31.test \
 txinfo32.test \
 txinfo33.test \
+txinfo-unrecognized-extension.test \
 transform.test \
 transform2.test \
 unused.test \
diff --git a/tests/txinfo-unrecognized-extension.test b/tests/txinfo-unrecognized-extension.test
new file mode 100755 (executable)
index 0000000..94f217f
--- /dev/null
@@ -0,0 +1,40 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# Test that automake complains properly when the files with unrecognized
+# extensions are passed to the TEXINFOS primary.
+
+. ./defs || Exit 1
+
+set -e
+
+cat > Makefile.am << 'END'
+info_TEXINFOS = foobar.foo bazquux.tex zardoz.c
+END
+
+echo '@setfilename foobar.info'  > foobar.foo
+echo '@setfilename bazquux.info' > bazquux.tex
+echo '@setfilename zardoz.info'  > zardoz.c
+: > texinfo.tex
+
+$ACLOCAL
+AUTOMAKE_fails
+
+for x in 'foobar\.foo' 'bazquux\.tex' 'zardoz\.c'; do
+  grep "^Makefile\\.am:.* texinfo file .*$x.* unrecognized extension" stderr
+done
+
+: