[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[6442] move util/tests
From: |
Gavin D. Smith |
Subject: |
[6442] move util/tests |
Date: |
Tue, 21 Jul 2015 15:43:44 +0000 |
Revision: 6442
http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=6442
Author: gavin
Date: 2015-07-21 15:43:43 +0000 (Tue, 21 Jul 2015)
Log Message:
-----------
move util/tests
Modified Paths:
--------------
trunk/ChangeLog
Added Paths:
-----------
trunk/contrib/nontests/
trunk/contrib/nontests/Makefile.am
trunk/contrib/nontests/README
trunk/contrib/nontests/automtest.sh
trunk/contrib/nontests/bibtex.test
trunk/contrib/nontests/defs.in
trunk/contrib/nontests/dvipdf.test
trunk/contrib/nontests/latex2html.test
trunk/contrib/nontests/local.test
trunk/contrib/nontests/texi2dvi.test
trunk/contrib/nontests/txitextest
Removed Paths:
-------------
trunk/util/tests/Makefile.am
trunk/util/tests/README
trunk/util/tests/automtest.sh
trunk/util/tests/bibtex.test
trunk/util/tests/defs.in
trunk/util/tests/dvipdf.test
trunk/util/tests/latex2html.test
trunk/util/tests/local.test
trunk/util/tests/texi2dvi.test
trunk/util/tests/txitextest
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/ChangeLog 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,5 +1,11 @@
2015-07-21 Gavin Smith <address@hidden>
+ * contrib/nontests: New directory. Move most of the files from
+ util/tests into it. Suggestion from Karl Berry on 7th July.
+ * contrib/tests/README: Say that tests were for util directory.
+
+2015-07-21 Gavin Smith <address@hidden>
+
* NEWS: Mention new command @validatemenus.
* tp/Texinfo/Common.pm (%default_parser_state_configuration):
Add validatemenus flag.
Copied: trunk/contrib/nontests/Makefile.am (from rev 6391,
trunk/util/tests/Makefile.am)
===================================================================
--- trunk/contrib/nontests/Makefile.am (rev 0)
+++ trunk/contrib/nontests/Makefile.am 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,11 @@
+# Makefile.am for texinfo/util/tests.
+#
+# Copyright 2008, 2009, 2010 Free Software Foundation, Inc.
+#
+# This file is free software; as a special exception the author gives
+# unlimited permission to copy and/or distribute it, with or without
+# modifications, as long as this notice is preserved.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Copied: trunk/contrib/nontests/README (from rev 6395, trunk/util/tests/README)
===================================================================
--- trunk/contrib/nontests/README (rev 0)
+++ trunk/contrib/nontests/README 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,20 @@
+$Id$
+texinfo/util/tests/README
+
+ Copyright 2015 Free Software Foundation, Inc.
+
+ Copying and distribution of this file, with or without modification,
+ are permitted in any medium without royalty provided the copyright
+ notice and this notice are preserved.
+
+These tests were for the util directory.
+
+Perhaps some day we will actually make these work. We can't just invoke
+them unconditionally, since people may or may not have working TeX
+installations. And even checking whether it is working or not is not
+simple.
+
+The txitextest script compares old and new results of running manuals
+through texinfo.tex. The texinfo.tex developer(s) run this from cron
+nightly as an imperfect check against errors and/or reversions creeping
+in.
Copied: trunk/contrib/nontests/automtest.sh (from rev 6391,
trunk/util/tests/automtest.sh)
===================================================================
--- trunk/contrib/nontests/automtest.sh (rev 0)
+++ trunk/contrib/nontests/automtest.sh 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,59 @@
+#!/bin/sh
+# Copyright 2012 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+# This is a basic test of whether the Texinfo support in automake works.
+# Both texi2dvi and makeinfo. Since it requires automake, we don't want
+# to enable it by default or anything.
+
+set -x; set -e; set -u
+
+mkdir foo.dir
+cd foo.dir
+
+mkdir sub
+
+cat > configure.ac <<'END'
+AC_INIT([try-texinfo], [1.0])
+AM_INIT_AUTOMAKE([foreign -Wall -Werror])
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
+END
+
+cat > Makefile.am <<'END'
+all-local: pdf dvi ps info
+info_TEXINFOS = sub/foobarbaz.texi
+END
+
+cat > sub/foobarbaz.texi <<'END'
+\input texinfo
address@hidden foobarbaz.info
address@hidden Zardoz
address@hidden Top
+Foo Bar.
address@hidden
+END
+
+autoreconf -vi
+grep ' -o.*foobarbaz\.texi' Makefile.in # Sanity check.
+./configure
+make
+test -f sub/foobarbaz.info
+test -f sub/foobarbaz.dvi
+test -f sub/foobarbaz.ps
+test -f sub/foobarbaz.pdf
+make distcheck
Copied: trunk/contrib/nontests/bibtex.test (from rev 6391,
trunk/util/tests/bibtex.test)
===================================================================
--- trunk/contrib/nontests/bibtex.test (rev 0)
+++ trunk/contrib/nontests/bibtex.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,57 @@
+#! /bin/sh
+# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+required='hevea'
+
+. ./defs || exit 1
+
+set -e
+
+create_input_tex <<EOF
+\cite{texinfo.doc}
+\bibliographystyle{plain}
+\bibliography{sample}
+EOF
+
+cat >sample.bib <<EOF
address@hidden,
+ title = "{GNU Texinfo}: The {GNU} documentation format",
+ author = "Robert J. Chassell and Richard M. Stallman",
+ year = "1988"
+}
+EOF
+
+
+# check HTML|INFO|TEXT|DVI|PDF
+# ----------------------------
+check ()
+{
+ out=$1
+ # Testing the local build mode.
+ TEXI2DVI_pass --$out --batch --tidy input.tex
+ # There should only be the DVI and the TEXI file.
+ assert_files input.$out input.tex sample.bib input.t2d
+ cp input.$out /tmp/foo
+ rm input.$out
+}
+
+# Currently we don't use bibtex with hevea. This is to be fixed.
+for out in dvi pdf # html info text
+do
+ check $out
+done
Copied: trunk/contrib/nontests/defs.in (from rev 6391, trunk/util/tests/defs.in)
===================================================================
--- trunk/contrib/nontests/defs.in (rev 0)
+++ trunk/contrib/nontests/defs.in 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,364 @@
+# -*- shell-script -*-
+# @configure_input@
+#
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
+# 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+#
+# (This file was originally part of GNU Automake.)
+#
+# 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 3 of the License, 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/>.
+
+# Defines for Automake testing environment.
+# Tom Tromey <address@hidden>
+
+# Be Bourne compatible.
+# (Snippet copied from configure's initialization in Autoconf 2.57.)
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
+ set -o posix
+fi
+
+# Ensure we are running from the right directory.
+test -f ./defs || {
+ echo "defs: not found in current directory" 1>&2
+ exit 1
+}
+
+# If srcdir is not set, then we are not running from `make check', be verbose.
+if test -z "$srcdir"; then
+ VERBOSE=x
+ # compute $srcdir.
+ srcdir=`echo "$0" | sed -e 's,/[^\\/]*$,,'`
+ test $srcdir = $0 && srcdir=.
+fi
+
+# Ensure $srcdir is set correctly.
+test -f $srcdir/defs.in || {
+ echo "$srcdir/defs.in not found, check \$srcdir" 1>&2
+ exit 1
+}
+
+me=`echo "$0" | sed -e 's,.*[\\/],,;s/\.test$//'`
+
+# See how redirections should work. User can set VERBOSE to see all
+# output.
+test -z "$VERBOSE" && {
+ exec > /dev/null 2>&1
+}
+
+# Make sure we override the user shell.
+SHELL='@SHELL@'
+export SHELL
+
+srcdir_abs=`cd $srcdir && pwd`
+test -z "$TEXI2DVI" && TEXI2DVI=$srcdir_abs/texi2dvi
+
+# be sure we use texi2dvi and texindex from our own directory, not
+# whatever happens to be in the path.
+echo "defs: prepending $srcdir_abs to PATH for testing."
+PATH="@abs_builddir@:@abs_srcdir@:$PATH"
+
+# Some shells forget to export modified environment variables.
+# (See note about `export' in the Autoconf manual.)
+export PATH
+
+# User can override various tools used.
+test -z "$PERL" && PERL='@PERL@'
+
+if test -n "$required"
+then
+ for tool in $required
+ do
+ # Check that each required tool is present.
+ case $tool in
+ hevea)
+ # HeVeA supports -version only. Use configure to find it.
+ test -n "@HEVEA@" || exit 77
+ ;;
+ tex)
+ # No all versions of Tex support `--version', so we use
+ # a configure check.
+ test -n "@TEX@" || exit 77
+ ;;
+ # Generic case: the tool must support --version.
+ *)
+ echo "$me: running $tool --version"
+ ( $tool --version ) || exit 77
+ ;;
+ esac
+ done
+fi
+
+
+# Always use an absolute srcdir. Otherwise symlinks made in subdirs
+# of the test dir just won't work.
+case "$srcdir" in
+ [\\/]* | ?:[\\/]*)
+ ;;
+
+ *)
+ srcdir=`CDPATH=: && cd "$srcdir" && pwd`
+ ;;
+esac
+
+chmod -R a+rwx testSubDir > /dev/null 2>&1
+rm -rf testSubDir > /dev/null 2>&1
+mkdir testSubDir
+
+# Copy in some files we need.
+cp $srcdir/../doc/texinfo.tex testSubDir || exit 1
+
+cd ./testSubDir
+
+
+# Unset the user's envvars that might change the behavior.
+unset TEXI2DVI_BUILD_MODE
+unset TEXI2DVI_BUILD_DIRECTORY
+
+echo "=== Running test $0"
+
+# POSIX no longer requires 'egrep' and 'fgrep',
+# but some hosts lack 'grep -E' and 'grep -F'.
+EGREP='@EGREP@'
+FGREP='@FGREP@'
+
+# The amount we should wait after modifying files depends on the platform.
+# For instance, Windows '95, '98 and ME have 2-second granularity
+# and can be up to 3 seconds in the future w.r.t. the system clock.
+sleep='sleep @MODIFICATION_DELAY@'
+
+# The tests call `make -e' but we do not want $srcdir from the environment
+# to override the definition from the Makefile.
+testsrcdir=$srcdir
+unset srcdir
+
+
+# create_input_texi < INPUT
+# -------------------------
+# Create input.texi adding stdin inside a default prologue/epilogue
+create_input_texi ()
+{
+ {
+ cat << END
+\input texinfo @c -*-texinfo-*-
address@hidden input
address@hidden input
+
address@hidden
address@hidden Top
address@hidden input
address@hidden ifnottex
+
+END
+ cat
+ cat << END
address@hidden
+END
+ } >input.texi
+}
+
+
+# create_input_tex < INPUT
+# ------------------------
+# Create input.tex adding stdin inside a default prologue/epilogue
+create_input_tex ()
+{
+ {
+ cat << END
+\documentclass{article}
+
+\begin{document}
+END
+ cat
+ cat << END
+\end{document}
+END
+ } >input.tex
+}
+
+
+# TEXI2DVI_run status [options...]
+# --------------------------------
+# Run texi2dvi with OPTIONS, and fail if does not exit with STATUS.
+TEXI2DVI_run ()
+{
+ expected_exitcode=$1
+ shift
+ exitcode=0
+ if test -n "$VERBOSE"; then
+ set x --debug --verbose ${1+"$@"}
+ shift
+ fi
+ texi2dvi ${1+"$@"} 2>stderr >stdout || exitcode=$?
+ cat stderr
+ cat stdout
+ test $exitcode = $expected_exitcode || exit 1
+}
+
+
+# TEXI2DVI_fail [options...]
+# ---------------------------
+# Run texi2dvi with OPTIONS, and fail if does not exit with failure.
+TEXI2DVI_fail ()
+{
+ TEXI2DVI_run 1 ${1+"$@"}
+}
+
+
+# TEXI2DVI_pass [options...]
+# ---------------------------
+# Run texi2dvi with OPTIONS, and fail if does not exit with failure.
+TEXI2DVI_pass ()
+{
+ TEXI2DVI_run 0 ${1+"$@"}
+}
+
+
+# optionset_get N OPTIONSET<1> -- OPTIONSET<2> -- ...
+# ---------------------------------------------------
+# Return OPTIONSET<N>
+optionset_get ()
+{
+ n=$1
+ shift
+ # Find the optionset.
+ while test $n != 1; do
+ case $1 in
+ --) n=`expr $n - 1`;;
+ esac
+ shift
+ done
+ # Return the optionset.
+ while true; do
+ case $#:$1 in
+ 0:) break;;
+ *:--) shift; break;;
+ *) echo "$1"; shift;;
+ esac
+ done
+}
+
+# list_files ()
+# -------------
+# Return the sorted list of files in this directory, except the "invisible"
ones.
+list_files ()
+{
+ for f in *
+ do
+ case $f in
+ texinfo.tex | stdout | stderr | ls.expected | ls.value );;
+ *) echo $f;;
+ esac
+ done | sort
+}
+
+
+# assert_files (EXPECTED-FILES)
+# -----------------------------
+# Only those files are valid in the current directory.
+assert_files ()
+{
+ if test -n "$VERBOSE"; then
+ ls
+ fi
+ list_files > ls.value
+ echo "$*" | tr ' ' '\n' | sort > ls.expected
+ diff -u ls.expected ls.value
+}
+
+
+# assert_and_remove_files (EXPECTED-FILES)
+# ----------------------------------------
+# Only those files are valid in the current directory. Remove them
+# afterwards.
+assert_and_remove_files ()
+{
+ assert_files "$@"
+ rm -rf "$@"
+}
+
+
+# title TITLE...
+# --------------
+# Make a huge title to ease the reading of the output.
+title ()
+{
+ (
+ set +x
+ echo " $@ " | sed -e 's/./=/g'
+ echo " $@ "
+ echo " $@ " | sed -e 's/./=/g'
+ )
+}
+
+# $latex_paragraph
+# ----------------
+# Some lengthy LaTeX.
+# grep -E '^[a-zA-Z]+$' /usr/share/dict/words | sed 200q | pr --page-width=76
--column=5 --omit-header
+latex_paragraph='
+A Acrux Aegean Ahmad Albany
+AOL Actaeon Aelfric Ahmadabad Albee
+Aachen Acton Aeneas Ahmed Alberio
+Aaliyah Acts Aeneid Ahriman Albert
+Aaron Acuff Aeolus Aida Alberta
+Abbas Ada Aeroflot Aiken Alberto
+Abbasid Adam Aeschylus Aileen Albigensian
+Abbott Adams Aesculapius Aimee Albion
+Abby Adan Aesop Ainu Albireo
+Abdul Adana Afghan Airedale Albuquerque
+Abe Adar Afghanistan Airedales Alcatraz
+Abel Addams Afghans Aisha Alcestis
+Abelard Adderley Africa Ajax Alcibiades
+Abelson Addie African Akbar Alcmena
+Aberdeen Addison Africans Akhmatova Alcoa
+Abernathy Adela Afrikaans Akihito Alcott
+Abidjan Adelaide Afrikaner Akita Alcuin
+Abigail Adele Afrikaners Akkad Alcyone
+Abilene Adeline Afro Akron Aldan
+Abner Aden Afrocentrism Al Aldebaran
+Abraham Adenauer Afros Ala Alden
+Abram Adhara Ag Alabama Alderamin
+Abrams Adidas Agamemnon Alabaman Aldo
+Absalom Adirondack Agassi Alabamans Aldrin
+Abuja Adirondacks Agassiz Alabamian Alec
+Abyssinia Adkins Agatha Alabamians Aleichem
+Abyssinian Adler Aggie Aladdin Alejandra
+Ac Adolf Aglaia Alamo Alejandro
+Acadia Adolfo Agnes Alamogordo Alembert
+Acapulco Adolph Agnew Alan Aleppo
+Accra Adonis Agni Alana Aleut
+Acevedo Adonises Agra Alar Aleutian
+Achaean Adrian Agricola Alaric Alex
+Achebe Adriana Agrippa Alaska Alexander
+Achernar Adriatic Agrippina Alaskan Alexandra
+Acheson Adrienne Aguilar Alaskans Alexandria
+Achilles Advent Aguinaldo Alba Alexei
+Aconcagua Adventist Aguirre Albania Alexis
+Acosta Advents Agustin Albanian Alfonso
+Acropolis Advil Ahab Albanians Alfonzo
+'
+
+
+# Turn on shell traces when VERBOSE is set.
+if test -n "$VERBOSE"; then
+ set -x
+else
+ :
+fi
+pwd
Copied: trunk/contrib/nontests/dvipdf.test (from rev 6391,
trunk/util/tests/dvipdf.test)
===================================================================
--- trunk/contrib/nontests/dvipdf.test (rev 0)
+++ trunk/contrib/nontests/dvipdf.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,66 @@
+#! /bin/sh
+# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+required='tex'
+
+. ./defs || exit 1
+
+set -e
+
+# one_run ARGS -- FILES
+# ---------------------
+# Run texi2dvi with ARGS, expect the FILES to be left. Remove them.
+one_run ()
+{
+ # Use pstricks.
+ cat >input.tex <<EOF
+\documentclass[a4paper]{article}
+\usepackage{pst-node}
+\pagestyle{empty}
+\begin{document}
+\begin{psmatrix}
+ A & B & C & D & E & F
+\end{psmatrix}
+\psset{arrows=->}
+\nccircle{1,1}{0.5}
+\nccircle[angleA=30]{1,2}{0.4}
+\nccircle[arrows=-,nodesep=0.05]{1,3}{0.2}
+\ncloop[angleB=180]{1,4}{1,4}
+\ncloop[angleB=180,linearc=0.35,nodesep=0.1]{1,5}{1,5}
+\ncloop[angleB=180,linearc=0.15,loopsize=0.4]{1,6}{1,6}
+
+\vspace{1cm}
+\begin{psmatrix}
+ A & B & C & D
+\end{psmatrix}
+\psset{arrows=->,nodesep=0.05}
+\ncangles[armA=0.8,armB=0,angleA=70,angleB=110,linearc=0.22]{1,1}{1,1}
+\ncdiag[arm=0.9,angleA=70,angleB=110,linearc=0.3]{1,2}{1,2}
+\ncdiag[arm=0.8,angleA=50,angleB=130,linearc=0.25]{1,3}{1,3}
+\ncdiag[arm=0.8,angleA=50,angleB=130,linearc=0.28]{1,4}{1,4}
+\end{document}
+EOF
+
+ TEXI2DVI_pass $(optionset_get 1 "$@") input.tex
+ # There should only be the expected and input files.
+ assert_and_remove_files $(optionset_get 2 "$@") input.tex
+}
+
+one_run --dvipdf --batch --clean \
+ -- \
+ input.pdf
Copied: trunk/contrib/nontests/latex2html.test (from rev 6391,
trunk/util/tests/latex2html.test)
===================================================================
--- trunk/contrib/nontests/latex2html.test (rev 0)
+++ trunk/contrib/nontests/latex2html.test 2015-07-21 15:43:43 UTC (rev
6442)
@@ -0,0 +1,79 @@
+#! /bin/sh
+# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+required='hevea'
+
+. ./defs || exit 1
+
+set -e
+
+# Force the creation of auxiliary files.
+# Force it to be big enough to trigger the info file splitting.
+{
+ echo "\tableofcontents"
+ for section in 1 2 3 4 5 6
+ do
+ echo "\section{$i}"
+ for subsection in 1 2 3 4 5 6
+ do
+ echo "\subsection{$i}"
+ echo "$latex_paragraph"
+ done
+ done
+} |
+create_input_tex
+
+
+# run_hevea_check FORMAT OPTIONS
+# ------------------------------
+run_hevea_check ()
+{
+ title "$@"
+
+ format="$1"
+ shift
+
+ # Testing the local build mode.
+ TEXI2DVI_pass --batch --$format "$@" input.tex
+
+ # Compute the expected output.
+ outfiles=input.$out
+ case $format in
+ info) outfiles="$outfiles input.info-1 input.info-2";;
+ esac
+
+ # Compute the aux files.
+ case $format:$@ in
+ *clean* ) auxfiles='';;
+ *tidy* ) auxfiles='input.t2d';;
+ html:*|text:* ) auxfiles='input.haux input.htoc';;
+ dvi:* ) auxfiles='input.aux input.log input.toc';;
+ * ) auxfiles='';;
+ esac
+ # There should only be the expected output and the source file.
+ assert_files input.tex $outfiles $auxfiles
+ rm -fr $outfiles $auxfiles
+}
+
+for opt in "" "--clean" "--tidy"
+do
+ for out in html info text
+ do
+ run_hevea_check $out $opt
+ done
+done
Copied: trunk/contrib/nontests/local.test (from rev 6391,
trunk/util/tests/local.test)
===================================================================
--- trunk/contrib/nontests/local.test (rev 0)
+++ trunk/contrib/nontests/local.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,59 @@
+#! /bin/sh
+# Copyright (C) 2003, 2005, 2007, 2008 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+# Make sure no "local" variable identifier is used twice, since
+# local is not actually portable.
+
+. ./defs || exit 1
+
+set -e
+
+# Make sure quotes are used to protect the value. See the comment in
+# texi2dvi itself about local.
+if sed -e 's/^[ ]*#.*//' $TEXI2DVI |
+ $EGREP "\blocal [a-zA-Z_0-9]*=[^\"']" |
+ $EGREP -v "\blocal [a-zA-Z_0-9]*=[a-zA-Z0-9]*$" |
+ grep .
+then
+ false
+else
+ true
+fi
+
+
+# Make sure each name is used only once.
+if sed -n -e 's/^#.*//' \
+ -e 's/local \([a-zA-Z_0-9]*\)/\1/gp' $TEXI2DVI |
+ sort |
+ uniq -c |
+ grep -v '^.*1 ' |
+ grep .
+then
+ false
+else
+ true
+fi
+
+
+# Make sure we don't use $().
+if $FGREP '$(' $TEXI2DVI
+then
+ false
+else
+ true
+fi
Copied: trunk/contrib/nontests/texi2dvi.test (from rev 6391,
trunk/util/tests/texi2dvi.test)
===================================================================
--- trunk/contrib/nontests/texi2dvi.test (rev 0)
+++ trunk/contrib/nontests/texi2dvi.test 2015-07-21 15:43:43 UTC (rev
6442)
@@ -0,0 +1,84 @@
+#! /bin/sh
+# Copyright (C) 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+#
+# This file is part of GNU Texinfo.
+#
+# GNU Texinfo 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 3 of the License,
+# or (at your option) any later version.
+#
+# GNU Texinfo 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/>.
+
+required='tex'
+
+. ./defs || exit 1
+
+set -e
+
+# one_run ARGS -- FILES
+# ---------------------
+# Run texi2dvi with ARGS, expect the FILES to be left. Remove them.
+one_run ()
+{
+ # Testing the local build mode.
+ # Use @foo to check that -t works properly.
+ echo "@foo" | create_input_texi
+ TEXI2DVI_pass $(optionset_get 1 "$@") \
+ -t '@macro foo' \
+ -t 'Foo' \
+ -t '@end macro' \
+ input.texi
+ # There should only be the expected FILES and the input file.
+ assert_and_remove_files $(optionset_get 2 "$@") input.texi
+}
+
+one_run --batch \
+ -- \
+ input.aux input.cp input.dvi input.fn input.ky input.log \
+ input.pg input.tp input.vr
+
+
+one_run --batch -o output.dvi \
+ -- \
+ input.aux input.cp input.fn input.ky input.log \
+ input.pg input.tp input.vr output.dvi
+
+
+# Testing the clean build mode.
+for mode in --clean --build=clean
+do
+ # There should only be the DVI and the TEXI file.
+ one_run $mode --batch -- input.dvi
+
+ # There should only be the DVI and the TEXI file.
+ one_run $mode --batch -o output.dvi -- output.dvi
+done
+
+
+# Testing the tidy build mode.
+one_run --build=tidy --batch -o output.dvi \
+ -- \
+ output.dvi output.t2d
+
+
+# mostly-clean should remove auxiliary files, but not the expected
+# output.
+touch output.dvi
+one_run --build=tidy --batch -o output.dvi --mostly-clean \
+ -- \
+ output.dvi
+
+
+# There should only be the DVI and the TEXI file.
+create_input_texi </dev/null
+cp input.texi input2.texi
+one_run --clean --batch input.texi input2.texi \
+ -- \
+ input2.dvi input2.texi input.dvi
Copied: trunk/contrib/nontests/txitextest (from rev 6391,
trunk/util/tests/txitextest)
===================================================================
--- trunk/contrib/nontests/txitextest (rev 0)
+++ trunk/contrib/nontests/txitextest 2015-07-21 15:43:43 UTC (rev 6442)
@@ -0,0 +1,94 @@
+#!/bin/sh
+# $Id$
+# Copyright 2006, 2011, 2012, 2013 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 3 of the License,
+# 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/>.
+#
+# Original author: Karl Berry.
+#
+# Test texinfo.tex changes by running various manuals through with an
+# old version, saving the .ps result from dvips, doing the same with a
+# new version, and comparing. Idea from Stepan Kasal.
+#
+# Another option is to run the manuals all the way through using
+# texi2dvi, which tests in another way.
+
+tsrc=`cd \`dirname $0\` && pwd`/../..
+PATH=$tsrc/util:$PATH
+
+tdoc=$tsrc/doc
+default_manuals="$tdoc/texinfo.texi $tdoc/info.texi $tdoc/info-stnd.texi"
+
+olddir=$tsrc/../gnulib/config
+newdir=$tdoc
+tempdir=$tsrc/@tests/test
+full=false
+manuals=
+
+while test $# -gt 0; do
+ case $1 in
+ --f*) full=true;;
+ --o*) shift; olddir="$1";;
+ --n*) shift; newdir="$1";;
+ --t*) shift; tempdir="$1";;
+ -*) echo "$0: unknown option \`$1'." >&2; exit 1;;
+ *) manuals="$manuals $1";;
+ esac
+ shift
+done
+
+test -z "$manuals" && manuals=$default_manuals
+initial_dir=`pwd`
+
+cd $tempdir || exit 1
+rm -f *
+
+run_tex() \
+{
+ TEXINPUTS=.:$mandir: tex $manual \
+ || { echo "$0: tex $manual failed." >&2; exit 1; }
+}
+
+for manual in $manuals; do
+ mandir=`dirname $manual`
+ test $mandir = . && mandir=$initial_dir
+ manual_base=`basename "$manual" | sed 's/\.[^.]*$//'`
+
+ rm -rf $manual_base.* texinfo.tex
+ ln -s $newdir/texinfo.tex texinfo.tex
+
+ if $full; then
+ # instead of comparing, do full test of just the new texinfo.tex.
+ echo "$0: testing $manual_base... (tex)"
+ texi2dvi $manual || { echo "texi2dvi $manual failed." >&2; exit 1; }
+ echo "$0: testing $manual_base... (pdf)"
+ texi2dvi --pdf $manual \
+ || { echo "texi2dvi --pdf $manual failed." >&2; exit 1; }
+
+ else
+ echo "$0: testing $manual_base... (new)"
+ run_tex
+ dvips $manual_base -o || exit 1
+ mv $manual_base.ps new.$manual_base.ps
+
+ echo "$0: testing $manual_base... (old)"
+ rm -rf $manual_base.* texinfo.tex
+ ln -s $olddir/texinfo.tex texinfo.tex
+ run_tex
+ dvips $manual_base -o || exit 1
+ mv $manual_base.ps old.$manual_base.ps
+
+ diff -U0 old.$manual_base.ps new.$manual_base.ps
+ fi
+done
Deleted: trunk/util/tests/Makefile.am
===================================================================
--- trunk/util/tests/Makefile.am 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/Makefile.am 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,11 +0,0 @@
-# Makefile.am for texinfo/util/tests.
-#
-# Copyright 2008, 2009, 2010 Free Software Foundation, Inc.
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Deleted: trunk/util/tests/README
===================================================================
--- trunk/util/tests/README 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/README 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,19 +0,0 @@
-$Id$
-texinfo/util/tests/README
-
- Copyright 2015 Free Software Foundation, Inc.
-
- Copying and distribution of this file, with or without modification,
- are permitted in any medium without royalty provided the copyright
- notice and this notice are preserved.
-
-Perhaps some day we will actually make these work. We can't just invoke
-them unconditionally, since people may or may not have working TeX
-installations. And even checking whether it is working or not is not
-simple.
-
-The txitextest script compares old and new results of running manuals
-through texinfo.tex. The texinfo.tex developer(s) run this from cron
-nightly as an imperfect check against errors and/or reversions creeping in.
-
-texi2dvi_helpversion.sh is run by "make check".
Deleted: trunk/util/tests/automtest.sh
===================================================================
--- trunk/util/tests/automtest.sh 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/automtest.sh 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,59 +0,0 @@
-#!/bin/sh
-# Copyright 2012 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-# This is a basic test of whether the Texinfo support in automake works.
-# Both texi2dvi and makeinfo. Since it requires automake, we don't want
-# to enable it by default or anything.
-
-set -x; set -e; set -u
-
-mkdir foo.dir
-cd foo.dir
-
-mkdir sub
-
-cat > configure.ac <<'END'
-AC_INIT([try-texinfo], [1.0])
-AM_INIT_AUTOMAKE([foreign -Wall -Werror])
-AC_CONFIG_FILES([Makefile])
-AC_OUTPUT
-END
-
-cat > Makefile.am <<'END'
-all-local: pdf dvi ps info
-info_TEXINFOS = sub/foobarbaz.texi
-END
-
-cat > sub/foobarbaz.texi <<'END'
-\input texinfo
address@hidden foobarbaz.info
address@hidden Zardoz
address@hidden Top
-Foo Bar.
address@hidden
-END
-
-autoreconf -vi
-grep ' -o.*foobarbaz\.texi' Makefile.in # Sanity check.
-./configure
-make
-test -f sub/foobarbaz.info
-test -f sub/foobarbaz.dvi
-test -f sub/foobarbaz.ps
-test -f sub/foobarbaz.pdf
-make distcheck
Deleted: trunk/util/tests/bibtex.test
===================================================================
--- trunk/util/tests/bibtex.test 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/bibtex.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,57 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-required='hevea'
-
-. ./defs || exit 1
-
-set -e
-
-create_input_tex <<EOF
-\cite{texinfo.doc}
-\bibliographystyle{plain}
-\bibliography{sample}
-EOF
-
-cat >sample.bib <<EOF
address@hidden,
- title = "{GNU Texinfo}: The {GNU} documentation format",
- author = "Robert J. Chassell and Richard M. Stallman",
- year = "1988"
-}
-EOF
-
-
-# check HTML|INFO|TEXT|DVI|PDF
-# ----------------------------
-check ()
-{
- out=$1
- # Testing the local build mode.
- TEXI2DVI_pass --$out --batch --tidy input.tex
- # There should only be the DVI and the TEXI file.
- assert_files input.$out input.tex sample.bib input.t2d
- cp input.$out /tmp/foo
- rm input.$out
-}
-
-# Currently we don't use bibtex with hevea. This is to be fixed.
-for out in dvi pdf # html info text
-do
- check $out
-done
Deleted: trunk/util/tests/defs.in
===================================================================
--- trunk/util/tests/defs.in 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/defs.in 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,364 +0,0 @@
-# -*- shell-script -*-
-# @configure_input@
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
-#
-# (This file was originally part of GNU Automake.)
-#
-# 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 3 of the License, 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/>.
-
-# Defines for Automake testing environment.
-# Tom Tromey <address@hidden>
-
-# Be Bourne compatible.
-# (Snippet copied from configure's initialization in Autoconf 2.57.)
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
- emulate sh
- NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
- set -o posix
-fi
-
-# Ensure we are running from the right directory.
-test -f ./defs || {
- echo "defs: not found in current directory" 1>&2
- exit 1
-}
-
-# If srcdir is not set, then we are not running from `make check', be verbose.
-if test -z "$srcdir"; then
- VERBOSE=x
- # compute $srcdir.
- srcdir=`echo "$0" | sed -e 's,/[^\\/]*$,,'`
- test $srcdir = $0 && srcdir=.
-fi
-
-# Ensure $srcdir is set correctly.
-test -f $srcdir/defs.in || {
- echo "$srcdir/defs.in not found, check \$srcdir" 1>&2
- exit 1
-}
-
-me=`echo "$0" | sed -e 's,.*[\\/],,;s/\.test$//'`
-
-# See how redirections should work. User can set VERBOSE to see all
-# output.
-test -z "$VERBOSE" && {
- exec > /dev/null 2>&1
-}
-
-# Make sure we override the user shell.
-SHELL='@SHELL@'
-export SHELL
-
-srcdir_abs=`cd $srcdir && pwd`
-test -z "$TEXI2DVI" && TEXI2DVI=$srcdir_abs/texi2dvi
-
-# be sure we use texi2dvi and texindex from our own directory, not
-# whatever happens to be in the path.
-echo "defs: prepending $srcdir_abs to PATH for testing."
-PATH="@abs_builddir@:@abs_srcdir@:$PATH"
-
-# Some shells forget to export modified environment variables.
-# (See note about `export' in the Autoconf manual.)
-export PATH
-
-# User can override various tools used.
-test -z "$PERL" && PERL='@PERL@'
-
-if test -n "$required"
-then
- for tool in $required
- do
- # Check that each required tool is present.
- case $tool in
- hevea)
- # HeVeA supports -version only. Use configure to find it.
- test -n "@HEVEA@" || exit 77
- ;;
- tex)
- # No all versions of Tex support `--version', so we use
- # a configure check.
- test -n "@TEX@" || exit 77
- ;;
- # Generic case: the tool must support --version.
- *)
- echo "$me: running $tool --version"
- ( $tool --version ) || exit 77
- ;;
- esac
- done
-fi
-
-
-# Always use an absolute srcdir. Otherwise symlinks made in subdirs
-# of the test dir just won't work.
-case "$srcdir" in
- [\\/]* | ?:[\\/]*)
- ;;
-
- *)
- srcdir=`CDPATH=: && cd "$srcdir" && pwd`
- ;;
-esac
-
-chmod -R a+rwx testSubDir > /dev/null 2>&1
-rm -rf testSubDir > /dev/null 2>&1
-mkdir testSubDir
-
-# Copy in some files we need.
-cp $srcdir/../doc/texinfo.tex testSubDir || exit 1
-
-cd ./testSubDir
-
-
-# Unset the user's envvars that might change the behavior.
-unset TEXI2DVI_BUILD_MODE
-unset TEXI2DVI_BUILD_DIRECTORY
-
-echo "=== Running test $0"
-
-# POSIX no longer requires 'egrep' and 'fgrep',
-# but some hosts lack 'grep -E' and 'grep -F'.
-EGREP='@EGREP@'
-FGREP='@FGREP@'
-
-# The amount we should wait after modifying files depends on the platform.
-# For instance, Windows '95, '98 and ME have 2-second granularity
-# and can be up to 3 seconds in the future w.r.t. the system clock.
-sleep='sleep @MODIFICATION_DELAY@'
-
-# The tests call `make -e' but we do not want $srcdir from the environment
-# to override the definition from the Makefile.
-testsrcdir=$srcdir
-unset srcdir
-
-
-# create_input_texi < INPUT
-# -------------------------
-# Create input.texi adding stdin inside a default prologue/epilogue
-create_input_texi ()
-{
- {
- cat << END
-\input texinfo @c -*-texinfo-*-
address@hidden input
address@hidden input
-
address@hidden
address@hidden Top
address@hidden input
address@hidden ifnottex
-
-END
- cat
- cat << END
address@hidden
-END
- } >input.texi
-}
-
-
-# create_input_tex < INPUT
-# ------------------------
-# Create input.tex adding stdin inside a default prologue/epilogue
-create_input_tex ()
-{
- {
- cat << END
-\documentclass{article}
-
-\begin{document}
-END
- cat
- cat << END
-\end{document}
-END
- } >input.tex
-}
-
-
-# TEXI2DVI_run status [options...]
-# --------------------------------
-# Run texi2dvi with OPTIONS, and fail if does not exit with STATUS.
-TEXI2DVI_run ()
-{
- expected_exitcode=$1
- shift
- exitcode=0
- if test -n "$VERBOSE"; then
- set x --debug --verbose ${1+"$@"}
- shift
- fi
- texi2dvi ${1+"$@"} 2>stderr >stdout || exitcode=$?
- cat stderr
- cat stdout
- test $exitcode = $expected_exitcode || exit 1
-}
-
-
-# TEXI2DVI_fail [options...]
-# ---------------------------
-# Run texi2dvi with OPTIONS, and fail if does not exit with failure.
-TEXI2DVI_fail ()
-{
- TEXI2DVI_run 1 ${1+"$@"}
-}
-
-
-# TEXI2DVI_pass [options...]
-# ---------------------------
-# Run texi2dvi with OPTIONS, and fail if does not exit with failure.
-TEXI2DVI_pass ()
-{
- TEXI2DVI_run 0 ${1+"$@"}
-}
-
-
-# optionset_get N OPTIONSET<1> -- OPTIONSET<2> -- ...
-# ---------------------------------------------------
-# Return OPTIONSET<N>
-optionset_get ()
-{
- n=$1
- shift
- # Find the optionset.
- while test $n != 1; do
- case $1 in
- --) n=`expr $n - 1`;;
- esac
- shift
- done
- # Return the optionset.
- while true; do
- case $#:$1 in
- 0:) break;;
- *:--) shift; break;;
- *) echo "$1"; shift;;
- esac
- done
-}
-
-# list_files ()
-# -------------
-# Return the sorted list of files in this directory, except the "invisible"
ones.
-list_files ()
-{
- for f in *
- do
- case $f in
- texinfo.tex | stdout | stderr | ls.expected | ls.value );;
- *) echo $f;;
- esac
- done | sort
-}
-
-
-# assert_files (EXPECTED-FILES)
-# -----------------------------
-# Only those files are valid in the current directory.
-assert_files ()
-{
- if test -n "$VERBOSE"; then
- ls
- fi
- list_files > ls.value
- echo "$*" | tr ' ' '\n' | sort > ls.expected
- diff -u ls.expected ls.value
-}
-
-
-# assert_and_remove_files (EXPECTED-FILES)
-# ----------------------------------------
-# Only those files are valid in the current directory. Remove them
-# afterwards.
-assert_and_remove_files ()
-{
- assert_files "$@"
- rm -rf "$@"
-}
-
-
-# title TITLE...
-# --------------
-# Make a huge title to ease the reading of the output.
-title ()
-{
- (
- set +x
- echo " $@ " | sed -e 's/./=/g'
- echo " $@ "
- echo " $@ " | sed -e 's/./=/g'
- )
-}
-
-# $latex_paragraph
-# ----------------
-# Some lengthy LaTeX.
-# grep -E '^[a-zA-Z]+$' /usr/share/dict/words | sed 200q | pr --page-width=76
--column=5 --omit-header
-latex_paragraph='
-A Acrux Aegean Ahmad Albany
-AOL Actaeon Aelfric Ahmadabad Albee
-Aachen Acton Aeneas Ahmed Alberio
-Aaliyah Acts Aeneid Ahriman Albert
-Aaron Acuff Aeolus Aida Alberta
-Abbas Ada Aeroflot Aiken Alberto
-Abbasid Adam Aeschylus Aileen Albigensian
-Abbott Adams Aesculapius Aimee Albion
-Abby Adan Aesop Ainu Albireo
-Abdul Adana Afghan Airedale Albuquerque
-Abe Adar Afghanistan Airedales Alcatraz
-Abel Addams Afghans Aisha Alcestis
-Abelard Adderley Africa Ajax Alcibiades
-Abelson Addie African Akbar Alcmena
-Aberdeen Addison Africans Akhmatova Alcoa
-Abernathy Adela Afrikaans Akihito Alcott
-Abidjan Adelaide Afrikaner Akita Alcuin
-Abigail Adele Afrikaners Akkad Alcyone
-Abilene Adeline Afro Akron Aldan
-Abner Aden Afrocentrism Al Aldebaran
-Abraham Adenauer Afros Ala Alden
-Abram Adhara Ag Alabama Alderamin
-Abrams Adidas Agamemnon Alabaman Aldo
-Absalom Adirondack Agassi Alabamans Aldrin
-Abuja Adirondacks Agassiz Alabamian Alec
-Abyssinia Adkins Agatha Alabamians Aleichem
-Abyssinian Adler Aggie Aladdin Alejandra
-Ac Adolf Aglaia Alamo Alejandro
-Acadia Adolfo Agnes Alamogordo Alembert
-Acapulco Adolph Agnew Alan Aleppo
-Accra Adonis Agni Alana Aleut
-Acevedo Adonises Agra Alar Aleutian
-Achaean Adrian Agricola Alaric Alex
-Achebe Adriana Agrippa Alaska Alexander
-Achernar Adriatic Agrippina Alaskan Alexandra
-Acheson Adrienne Aguilar Alaskans Alexandria
-Achilles Advent Aguinaldo Alba Alexei
-Aconcagua Adventist Aguirre Albania Alexis
-Acosta Advents Agustin Albanian Alfonso
-Acropolis Advil Ahab Albanians Alfonzo
-'
-
-
-# Turn on shell traces when VERBOSE is set.
-if test -n "$VERBOSE"; then
- set -x
-else
- :
-fi
-pwd
Deleted: trunk/util/tests/dvipdf.test
===================================================================
--- trunk/util/tests/dvipdf.test 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/dvipdf.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,66 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-required='tex'
-
-. ./defs || exit 1
-
-set -e
-
-# one_run ARGS -- FILES
-# ---------------------
-# Run texi2dvi with ARGS, expect the FILES to be left. Remove them.
-one_run ()
-{
- # Use pstricks.
- cat >input.tex <<EOF
-\documentclass[a4paper]{article}
-\usepackage{pst-node}
-\pagestyle{empty}
-\begin{document}
-\begin{psmatrix}
- A & B & C & D & E & F
-\end{psmatrix}
-\psset{arrows=->}
-\nccircle{1,1}{0.5}
-\nccircle[angleA=30]{1,2}{0.4}
-\nccircle[arrows=-,nodesep=0.05]{1,3}{0.2}
-\ncloop[angleB=180]{1,4}{1,4}
-\ncloop[angleB=180,linearc=0.35,nodesep=0.1]{1,5}{1,5}
-\ncloop[angleB=180,linearc=0.15,loopsize=0.4]{1,6}{1,6}
-
-\vspace{1cm}
-\begin{psmatrix}
- A & B & C & D
-\end{psmatrix}
-\psset{arrows=->,nodesep=0.05}
-\ncangles[armA=0.8,armB=0,angleA=70,angleB=110,linearc=0.22]{1,1}{1,1}
-\ncdiag[arm=0.9,angleA=70,angleB=110,linearc=0.3]{1,2}{1,2}
-\ncdiag[arm=0.8,angleA=50,angleB=130,linearc=0.25]{1,3}{1,3}
-\ncdiag[arm=0.8,angleA=50,angleB=130,linearc=0.28]{1,4}{1,4}
-\end{document}
-EOF
-
- TEXI2DVI_pass $(optionset_get 1 "$@") input.tex
- # There should only be the expected and input files.
- assert_and_remove_files $(optionset_get 2 "$@") input.tex
-}
-
-one_run --dvipdf --batch --clean \
- -- \
- input.pdf
Deleted: trunk/util/tests/latex2html.test
===================================================================
--- trunk/util/tests/latex2html.test 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/latex2html.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,79 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2006, 2007 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-required='hevea'
-
-. ./defs || exit 1
-
-set -e
-
-# Force the creation of auxiliary files.
-# Force it to be big enough to trigger the info file splitting.
-{
- echo "\tableofcontents"
- for section in 1 2 3 4 5 6
- do
- echo "\section{$i}"
- for subsection in 1 2 3 4 5 6
- do
- echo "\subsection{$i}"
- echo "$latex_paragraph"
- done
- done
-} |
-create_input_tex
-
-
-# run_hevea_check FORMAT OPTIONS
-# ------------------------------
-run_hevea_check ()
-{
- title "$@"
-
- format="$1"
- shift
-
- # Testing the local build mode.
- TEXI2DVI_pass --batch --$format "$@" input.tex
-
- # Compute the expected output.
- outfiles=input.$out
- case $format in
- info) outfiles="$outfiles input.info-1 input.info-2";;
- esac
-
- # Compute the aux files.
- case $format:$@ in
- *clean* ) auxfiles='';;
- *tidy* ) auxfiles='input.t2d';;
- html:*|text:* ) auxfiles='input.haux input.htoc';;
- dvi:* ) auxfiles='input.aux input.log input.toc';;
- * ) auxfiles='';;
- esac
- # There should only be the expected output and the source file.
- assert_files input.tex $outfiles $auxfiles
- rm -fr $outfiles $auxfiles
-}
-
-for opt in "" "--clean" "--tidy"
-do
- for out in html info text
- do
- run_hevea_check $out $opt
- done
-done
Deleted: trunk/util/tests/local.test
===================================================================
--- trunk/util/tests/local.test 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/local.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,59 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2003, 2005, 2007, 2008 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-# Make sure no "local" variable identifier is used twice, since
-# local is not actually portable.
-
-. ./defs || exit 1
-
-set -e
-
-# Make sure quotes are used to protect the value. See the comment in
-# texi2dvi itself about local.
-if sed -e 's/^[ ]*#.*//' $TEXI2DVI |
- $EGREP "\blocal [a-zA-Z_0-9]*=[^\"']" |
- $EGREP -v "\blocal [a-zA-Z_0-9]*=[a-zA-Z0-9]*$" |
- grep .
-then
- false
-else
- true
-fi
-
-
-# Make sure each name is used only once.
-if sed -n -e 's/^#.*//' \
- -e 's/local \([a-zA-Z_0-9]*\)/\1/gp' $TEXI2DVI |
- sort |
- uniq -c |
- grep -v '^.*1 ' |
- grep .
-then
- false
-else
- true
-fi
-
-
-# Make sure we don't use $().
-if $FGREP '$(' $TEXI2DVI
-then
- false
-else
- true
-fi
Deleted: trunk/util/tests/texi2dvi.test
===================================================================
--- trunk/util/tests/texi2dvi.test 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/texi2dvi.test 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,84 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
-#
-# This file is part of GNU Texinfo.
-#
-# GNU Texinfo 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 3 of the License,
-# or (at your option) any later version.
-#
-# GNU Texinfo 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/>.
-
-required='tex'
-
-. ./defs || exit 1
-
-set -e
-
-# one_run ARGS -- FILES
-# ---------------------
-# Run texi2dvi with ARGS, expect the FILES to be left. Remove them.
-one_run ()
-{
- # Testing the local build mode.
- # Use @foo to check that -t works properly.
- echo "@foo" | create_input_texi
- TEXI2DVI_pass $(optionset_get 1 "$@") \
- -t '@macro foo' \
- -t 'Foo' \
- -t '@end macro' \
- input.texi
- # There should only be the expected FILES and the input file.
- assert_and_remove_files $(optionset_get 2 "$@") input.texi
-}
-
-one_run --batch \
- -- \
- input.aux input.cp input.dvi input.fn input.ky input.log \
- input.pg input.tp input.vr
-
-
-one_run --batch -o output.dvi \
- -- \
- input.aux input.cp input.fn input.ky input.log \
- input.pg input.tp input.vr output.dvi
-
-
-# Testing the clean build mode.
-for mode in --clean --build=clean
-do
- # There should only be the DVI and the TEXI file.
- one_run $mode --batch -- input.dvi
-
- # There should only be the DVI and the TEXI file.
- one_run $mode --batch -o output.dvi -- output.dvi
-done
-
-
-# Testing the tidy build mode.
-one_run --build=tidy --batch -o output.dvi \
- -- \
- output.dvi output.t2d
-
-
-# mostly-clean should remove auxiliary files, but not the expected
-# output.
-touch output.dvi
-one_run --build=tidy --batch -o output.dvi --mostly-clean \
- -- \
- output.dvi
-
-
-# There should only be the DVI and the TEXI file.
-create_input_texi </dev/null
-cp input.texi input2.texi
-one_run --clean --batch input.texi input2.texi \
- -- \
- input2.dvi input2.texi input.dvi
Deleted: trunk/util/tests/txitextest
===================================================================
--- trunk/util/tests/txitextest 2015-07-21 15:16:29 UTC (rev 6441)
+++ trunk/util/tests/txitextest 2015-07-21 15:43:43 UTC (rev 6442)
@@ -1,94 +0,0 @@
-#!/bin/sh
-# $Id$
-# Copyright 2006, 2011, 2012, 2013 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 3 of the License,
-# 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/>.
-#
-# Original author: Karl Berry.
-#
-# Test texinfo.tex changes by running various manuals through with an
-# old version, saving the .ps result from dvips, doing the same with a
-# new version, and comparing. Idea from Stepan Kasal.
-#
-# Another option is to run the manuals all the way through using
-# texi2dvi, which tests in another way.
-
-tsrc=`cd \`dirname $0\` && pwd`/../..
-PATH=$tsrc/util:$PATH
-
-tdoc=$tsrc/doc
-default_manuals="$tdoc/texinfo.texi $tdoc/info.texi $tdoc/info-stnd.texi"
-
-olddir=$tsrc/../gnulib/config
-newdir=$tdoc
-tempdir=$tsrc/@tests/test
-full=false
-manuals=
-
-while test $# -gt 0; do
- case $1 in
- --f*) full=true;;
- --o*) shift; olddir="$1";;
- --n*) shift; newdir="$1";;
- --t*) shift; tempdir="$1";;
- -*) echo "$0: unknown option \`$1'." >&2; exit 1;;
- *) manuals="$manuals $1";;
- esac
- shift
-done
-
-test -z "$manuals" && manuals=$default_manuals
-initial_dir=`pwd`
-
-cd $tempdir || exit 1
-rm -f *
-
-run_tex() \
-{
- TEXINPUTS=.:$mandir: tex $manual \
- || { echo "$0: tex $manual failed." >&2; exit 1; }
-}
-
-for manual in $manuals; do
- mandir=`dirname $manual`
- test $mandir = . && mandir=$initial_dir
- manual_base=`basename "$manual" | sed 's/\.[^.]*$//'`
-
- rm -rf $manual_base.* texinfo.tex
- ln -s $newdir/texinfo.tex texinfo.tex
-
- if $full; then
- # instead of comparing, do full test of just the new texinfo.tex.
- echo "$0: testing $manual_base... (tex)"
- texi2dvi $manual || { echo "texi2dvi $manual failed." >&2; exit 1; }
- echo "$0: testing $manual_base... (pdf)"
- texi2dvi --pdf $manual \
- || { echo "texi2dvi --pdf $manual failed." >&2; exit 1; }
-
- else
- echo "$0: testing $manual_base... (new)"
- run_tex
- dvips $manual_base -o || exit 1
- mv $manual_base.ps new.$manual_base.ps
-
- echo "$0: testing $manual_base... (old)"
- rm -rf $manual_base.* texinfo.tex
- ln -s $olddir/texinfo.tex texinfo.tex
- run_tex
- dvips $manual_base -o || exit 1
- mv $manual_base.ps old.$manual_base.ps
-
- diff -U0 old.$manual_base.ps new.$manual_base.ps
- fi
-done
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [6442] move util/tests,
Gavin D. Smith <=