diff options
-rw-r--r-- | tests/ls-2/Makefile.am | 39 | ||||
-rw-r--r-- | tests/ls-2/Makefile.in | 247 | ||||
-rw-r--r-- | tests/ls-2/Test.pm | 31 | ||||
-rwxr-xr-x | tests/ls-2/ls-tests | 288 |
4 files changed, 605 insertions, 0 deletions
diff --git a/tests/ls-2/Makefile.am b/tests/ls-2/Makefile.am new file mode 100644 index 000000000..0bb467fb8 --- /dev/null +++ b/tests/ls-2/Makefile.am @@ -0,0 +1,39 @@ +## Process this file with automake to produce Makefile.in -*-Makefile-*-. + +##test-files-begin +x = ls +explicit = +maint_gen = q q-.X q-N.X q-Q.X q-q.X q-qs-c.X q-qs-esc.X q-qs-lit.X \ +q-qs-sh-a.X q-qs-sh.X +run_gen = q-.O q-.E q-N.O q-N.E q-q.O q-q.E q-Q.O q-Q.E q-qs-lit.O q-qs-lit.E \ +q-qs-sh.O q-qs-sh.E q-qs-sh-a.O q-qs-sh-a.E q-qs-c.O q-qs-c.E q-qs-esc.O \ +q-qs-esc.E +##test-files-end + +EXTRA_DIST = Test.pm $x-tests $(explicit) $(maint_gen) +noinst_SCRIPTS = $x-tests + +PERL = @PERL@ +editpl = sed -e 's,@''PERL''@,$(PERL),g' -e 's,@''srcdir''@,@srcdir@,g' + +TESTS = $x-tests + +mk_script = $(srcdir)/../mk-script +$(srcdir)/$x-tests: $(mk_script) Test.pm + $(PERL) -I. -w -- $(mk_script) ../../src/$x > $@.n + mv $@.n $@ + chmod 755 $@ + +MAINTAINERCLEANFILES = $x-tests $(maint_gen) +CLEANFILES = $(run_gen) + +check: $(maint_gen) + +Makefile.am: ../Makefile.am.in Test.pm $(mk_script) + rm -f $@ $@t + sed -n '1,/^##test-files-begin/p' $< > $@t + tool=`echo $(subdir)|sed 's/^tests.//;s/-test//;s/-[0-9]$$//'`; \ + echo "x = $$tool" >> $@t + $(PERL) -I. -w -- $(mk_script) --list >> $@t + sed -n '/^##test-files-end/,$$p' $< >> $@t + mv $@t $@ diff --git a/tests/ls-2/Makefile.in b/tests/ls-2/Makefile.in new file mode 100644 index 000000000..f5ca1e020 --- /dev/null +++ b/tests/ls-2/Makefile.in @@ -0,0 +1,247 @@ +# Makefile.in generated automatically by automake 1.3 from Makefile.am + +# Copyright (C) 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc. +# This Makefile.in is free software; the Free Software Foundation +# 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. + + +SHELL = /bin/sh + +srcdir = @srcdir@ +top_srcdir = @top_srcdir@ +VPATH = @srcdir@ +prefix = @prefix@ +exec_prefix = @exec_prefix@ + +bindir = @bindir@ +sbindir = @sbindir@ +libexecdir = @libexecdir@ +datadir = @datadir@ +sysconfdir = @sysconfdir@ +sharedstatedir = @sharedstatedir@ +localstatedir = @localstatedir@ +libdir = @libdir@ +infodir = @infodir@ +mandir = @mandir@ +includedir = @includedir@ +oldincludedir = /usr/include + +DISTDIR = + +pkgdatadir = $(datadir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ + +top_builddir = ../.. + +ACLOCAL = @ACLOCAL@ +AUTOCONF = @AUTOCONF@ +AUTOMAKE = @AUTOMAKE@ +AUTOHEADER = @AUTOHEADER@ + +INSTALL = @INSTALL@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +transform = @program_transform_name@ + +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +CATALOGS = @CATALOGS@ +CATOBJEXT = @CATOBJEXT@ +CC = @CC@ +CPP = @CPP@ +DATADIRNAME = @DATADIRNAME@ +DF_PROG = @DF_PROG@ +GENCAT = @GENCAT@ +GMOFILES = @GMOFILES@ +GMSGFMT = @GMSGFMT@ +GT_NO = @GT_NO@ +GT_YES = @GT_YES@ +INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@ +INSTOBJEXT = @INSTOBJEXT@ +INTLDEPS = @INTLDEPS@ +INTLLIBS = @INTLLIBS@ +INTLOBJS = @INTLOBJS@ +LIBOBJS = @LIBOBJS@ +MAKEINFO = @MAKEINFO@ +MKINSTALLDIRS = @MKINSTALLDIRS@ +MSGFMT = @MSGFMT@ +MVDIR_PROG = @MVDIR_PROG@ +PACKAGE = @PACKAGE@ +POFILES = @POFILES@ +POSUB = @POSUB@ +RANLIB = @RANLIB@ +U = @U@ +USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@ +USE_NLS = @USE_NLS@ +VERSION = @VERSION@ +YACC = @YACC@ +l = @l@ + +x = ls +explicit = +maint_gen = q q-.X q-N.X q-Q.X q-q.X q-qs-c.X q-qs-esc.X q-qs-lit.X \ +q-qs-sh-a.X q-qs-sh.X +run_gen = q-.O q-.E q-N.O q-N.E q-q.O q-q.E q-Q.O q-Q.E q-qs-lit.O q-qs-lit.E \ +q-qs-sh.O q-qs-sh.E q-qs-sh-a.O q-qs-sh-a.E q-qs-c.O q-qs-c.E q-qs-esc.O \ +q-qs-esc.E + +EXTRA_DIST = Test.pm $x-tests $(explicit) $(maint_gen) +noinst_SCRIPTS = $x-tests + +PERL = @PERL@ +editpl = sed -e 's,@''PERL''@,$(PERL),g' -e 's,@''srcdir''@,@srcdir@,g' + +TESTS = $x-tests + +mk_script = $(srcdir)/../mk-script + +MAINTAINERCLEANFILES = $x-tests $(maint_gen) +CLEANFILES = $(run_gen) +mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs +CONFIG_HEADER = ../../config.h +CONFIG_CLEAN_FILES = +SCRIPTS = $(noinst_SCRIPTS) + +DIST_COMMON = Makefile.am Makefile.in + + +DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) + +TAR = tar +GZIP = --best +all: Makefile $(SCRIPTS) + +.SUFFIXES: +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) + cd $(top_srcdir) && $(AUTOMAKE) --gnits tests/ls-2/Makefile + +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) + cd $(top_builddir) \ + && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status + +tags: TAGS +TAGS: + + +distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) + +subdir = tests/ls-2 + +distdir: $(DISTFILES) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(top_distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnits tests/ls-2/Makefile + @for file in $(DISTFILES); do \ + d=$(srcdir); \ + test -f $(distdir)/$$file \ + || ln $$d/$$file $(distdir)/$$file 2> /dev/null \ + || cp -p $$d/$$file $(distdir)/$$file; \ + done +check-TESTS: $(TESTS) + @failed=0; all=0; \ + srcdir=$(srcdir); export srcdir; \ + for tst in $(TESTS); do \ + if test -f $$tst; then dir=.; \ + else dir="$(srcdir)"; fi; \ + if $(TESTS_ENVIRONMENT) $$dir/$$tst; then \ + all=`expr $$all + 1`; \ + echo "PASS: $$tst"; \ + elif test $$? -ne 77; then \ + all=`expr $$all + 1`; \ + failed=`expr $$failed + 1`; \ + echo "FAIL: $$tst"; \ + fi; \ + done; \ + if test "$$failed" -eq 0; then \ + banner="All $$all tests passed"; \ + else \ + banner="$$failed of $$all tests failed"; \ + fi; \ + dashes=`echo "$$banner" | sed s/./=/g`; \ + echo "$$dashes"; \ + echo "$$banner"; \ + echo "$$dashes"; \ + test "$$failed" -eq 0 +info: +dvi: +check: all + $(MAKE) check-TESTS +installcheck: +install-exec: + @$(NORMAL_INSTALL) + +install-data: + @$(NORMAL_INSTALL) + +install: install-exec install-data all + @: + +uninstall: + +install-strip: + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' INSTALL_SCRIPT='$(INSTALL_PROGRAM)' install +installdirs: + + +mostlyclean-generic: + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -rm -f Makefile $(DISTCLEANFILES) + -rm -f config.cache config.log stamp-h stamp-h[0-9]* + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + +maintainer-clean-generic: + -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) +mostlyclean: mostlyclean-generic + +clean: clean-generic mostlyclean + +distclean: distclean-generic clean + -rm -f config.status + +maintainer-clean: maintainer-clean-generic distclean + @echo "This command is intended for maintainers to use;" + @echo "it deletes files that may require special tools to rebuild." + +.PHONY: tags distdir check-TESTS info dvi installcheck install-exec \ +install-data install uninstall all installdirs mostlyclean-generic \ +distclean-generic clean-generic maintainer-clean-generic clean \ +mostlyclean distclean maintainer-clean + +$(srcdir)/$x-tests: $(mk_script) Test.pm + $(PERL) -I. -w -- $(mk_script) ../../src/$x > $@.n + mv $@.n $@ + chmod 755 $@ + +check: $(maint_gen) + +Makefile.am: ../Makefile.am.in Test.pm $(mk_script) + rm -f $@ $@t + sed -n '1,/^##test-files-begin/p' $< > $@t + tool=`echo $(subdir)|sed 's/^tests.//;s/-test//;s/-[0-9]$$//'`; \ + echo "x = $$tool" >> $@t + $(PERL) -I. -w -- $(mk_script) --list >> $@t + sed -n '/^##test-files-end/,$$p' $< >> $@t + mv $@t $@ + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/tests/ls-2/Test.pm b/tests/ls-2/Test.pm new file mode 100644 index 000000000..d98f55875 --- /dev/null +++ b/tests/ls-2/Test.pm @@ -0,0 +1,31 @@ +# -*-perl-*- +package Test; +require 5.002; +use strict; + +# Always copy filename arguments from $srcdir to current directory +# before running ls on them. Otherwise, we'd have to factor out +# differences in $srcdir from the expected output. +$Test::copy_fileargs_default = 1; + +sub test_vector +{ + my @tv = + ( + # test-name options input expected-output expected-return-code + # + ['q-', '', {"q\a" => 'contents'}, "q\a\n", 0], + ['q-N', '-N', {"q\a" => ''}, "q\a\n", 0], + ['q-q', '-q', {"q\a" => ''}, "q?\n", 0], + ['q-Q', '-Q', {"q\a" => ''}, "\"q\\a\"\n", 0], + ['q-qs-lit', '--quoting=literal', {"q\a" => ''}, "q\a\n", 0], + ['q-qs-sh', '--quoting=shell', {"q\a" => ''}, "q\a\n", 0], + ['q-qs-sh-a', '--quoting=shell-always', {"q\a" => ''}, "'q\a'\n", 0], + ['q-qs-c', '--quoting=c', {"q\a" => ''}, "\"q\\a\"\n", 0], + ['q-qs-esc', '--quoting=escape', {"q\a" => ''}, "q\\a\n", 0], + ); + + return @tv; +} + +1; diff --git a/tests/ls-2/ls-tests b/tests/ls-2/ls-tests new file mode 100755 index 000000000..e43ee167a --- /dev/null +++ b/tests/ls-2/ls-tests @@ -0,0 +1,288 @@ +#! /bin/sh +# This script was generated automatically by ./../mk-script. +case $# in + 0) xx='../../src/ls';; + *) xx="$1";; +esac +test "$VERBOSE" && echo=echo || echo=: +$echo testing program: $xx +errors=0 +test "$srcdir" || srcdir=. +test "$VERBOSE" && $xx --version 2> /dev/null + +# Make sure we get English translations. +LANGUAGE=C +export LANGUAGE +LC_ALL=C +export LC_ALL +LANG=C +export LANG + +filename_args="$srcdir/quotable" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx $filename_args > q-.O 2> q-.E +code=$? +if test $code != 0 ; then + $echo "Test q- failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-.O $srcdir/q-.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-"; fi ;; + 1) $echo "Test q- failed: files q-.O and $srcdir/q-.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q- may have failed." 1>&2; + $echo The command "cmp q-.O $srcdir/q-.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-.E || rm -f q-.E +filename_args="$srcdir/quotable" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx -N $filename_args > q-N.O 2> q-N.E +code=$? +if test $code != 0 ; then + $echo "Test q-N failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-N.O $srcdir/q-N.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-N"; fi ;; + 1) $echo "Test q-N failed: files q-N.O and $srcdir/q-N.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-N may have failed." 1>&2; + $echo The command "cmp q-N.O $srcdir/q-N.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-N.E || rm -f q-N.E +filename_args="$srcdir/quotable" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx -q $filename_args > q-q.O 2> q-q.E +code=$? +if test $code != 0 ; then + $echo "Test q-q failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-q.O $srcdir/q-q.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-q"; fi ;; + 1) $echo "Test q-q failed: files q-q.O and $srcdir/q-q.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-q may have failed." 1>&2; + $echo The command "cmp q-q.O $srcdir/q-q.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-q.E || rm -f q-q.E +filename_args="$srcdir/quotable" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx -Q $filename_args > q-Q.O 2> q-Q.E +code=$? +if test $code != 0 ; then + $echo "Test q-Q failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-Q.O $srcdir/q-Q.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-Q"; fi ;; + 1) $echo "Test q-Q failed: files q-Q.O and $srcdir/q-Q.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-Q may have failed." 1>&2; + $echo The command "cmp q-Q.O $srcdir/q-Q.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-Q.E || rm -f q-Q.E +filename_args="$srcdir/q" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx --quoting=literal $filename_args > q-qs-lit.O 2> q-qs-lit.E +code=$? +if test $code != 0 ; then + $echo "Test q-qs-lit failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-qs-lit.O $srcdir/q-qs-lit.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-qs-lit"; fi ;; + 1) $echo "Test q-qs-lit failed: files q-qs-lit.O and $srcdir/q-qs-lit.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-qs-lit may have failed." 1>&2; + $echo The command "cmp q-qs-lit.O $srcdir/q-qs-lit.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-qs-lit.E || rm -f q-qs-lit.E +filename_args="$srcdir/q" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx --quoting=shell $filename_args > q-qs-sh.O 2> q-qs-sh.E +code=$? +if test $code != 0 ; then + $echo "Test q-qs-sh failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-qs-sh.O $srcdir/q-qs-sh.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-qs-sh"; fi ;; + 1) $echo "Test q-qs-sh failed: files q-qs-sh.O and $srcdir/q-qs-sh.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-qs-sh may have failed." 1>&2; + $echo The command "cmp q-qs-sh.O $srcdir/q-qs-sh.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-qs-sh.E || rm -f q-qs-sh.E +filename_args="$srcdir/q" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx --quoting=shell-always $filename_args > q-qs-sh-a.O 2> q-qs-sh-a.E +code=$? +if test $code != 0 ; then + $echo "Test q-qs-sh-a failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-qs-sh-a.O $srcdir/q-qs-sh-a.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-qs-sh-a"; fi ;; + 1) $echo "Test q-qs-sh-a failed: files q-qs-sh-a.O and $srcdir/q-qs-sh-a.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-qs-sh-a may have failed." 1>&2; + $echo The command "cmp q-qs-sh-a.O $srcdir/q-qs-sh-a.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-qs-sh-a.E || rm -f q-qs-sh-a.E +filename_args="$srcdir/q" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx --quoting=c $filename_args > q-qs-c.O 2> q-qs-c.E +code=$? +if test $code != 0 ; then + $echo "Test q-qs-c failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-qs-c.O $srcdir/q-qs-c.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-qs-c"; fi ;; + 1) $echo "Test q-qs-c failed: files q-qs-c.O and $srcdir/q-qs-c.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-qs-c may have failed." 1>&2; + $echo The command "cmp q-qs-c.O $srcdir/q-qs-c.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-qs-c.E || rm -f q-qs-c.E +filename_args="$srcdir/q" +new_filename_args= +for arg in $filename_args; do + if test -r $arg; then + basename_arg=`echo $arg|sed 's,.*/,,'` + test -f $basename_arg || cp -a $arg . + arg=$basename_arg + fi + new_filename_args="$new_filename_args $arg" +done +filename_args=$new_filename_args + +$xx --quoting=escape $filename_args > q-qs-esc.O 2> q-qs-esc.E +code=$? +if test $code != 0 ; then + $echo "Test q-qs-esc failed: ../../src/ls return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp q-qs-esc.O $srcdir/q-qs-esc.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE" ; then $echo "passed q-qs-esc"; fi ;; + 1) $echo "Test q-qs-esc failed: files q-qs-esc.O and $srcdir/q-qs-esc.X differ" 1>&2; + errors=`expr $errors + 1` ;; + 2) $echo "Test q-qs-esc may have failed." 1>&2; + $echo The command "cmp q-qs-esc.O $srcdir/q-qs-esc.X" failed. 1>&2 ; + errors=`expr $errors + 1` ;; + esac +fi +test -s q-qs-esc.E || rm -f q-qs-esc.E +if test $errors = 0 ; then + $echo Passed all 9 tests. 1>&2 +else + $echo Failed $errors tests. 1>&2 +fi +test $errors = 0 || errors=1 +exit $errors |