1#! /bin/sh
2# Generated from testsuite.at by GNU Autoconf 2.69.
3#
4# Copyright (C) 2009-2012 Free Software Foundation, Inc.
5#
6# This test suite is free software; the Free Software Foundation gives
7# unlimited permission to copy, distribute and modify it.
8## -------------------- ##
9## M4sh Initialization. ##
10## -------------------- ##
11
12# Be more Bourne compatible
13DUALCASE=1; export DUALCASE # for MKS sh
14if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
15  emulate sh
16  NULLCMD=:
17  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
18  # is contrary to our usage.  Disable this feature.
19  alias -g '${1+"$@"}'='"$@"'
20  setopt NO_GLOB_SUBST
21else
22  case `(set -o) 2>/dev/null` in #(
23  *posix*) :
24    set -o posix ;; #(
25  *) :
26     ;;
27esac
28fi
29
30
31as_nl='
32'
33export as_nl
34# Printing a long string crashes Solaris 7 /usr/bin/printf.
35as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
36as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
37as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
38# Prefer a ksh shell builtin over an external printf program on Solaris,
39# but without wasting forks for bash or zsh.
40if test -z "$BASH_VERSION$ZSH_VERSION" \
41    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
42  as_echo='print -r --'
43  as_echo_n='print -rn --'
44elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
45  as_echo='printf %s\n'
46  as_echo_n='printf %s'
47else
48  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
49    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
50    as_echo_n='/usr/ucb/echo -n'
51  else
52    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
53    as_echo_n_body='eval
54      arg=$1;
55      case $arg in #(
56      *"$as_nl"*)
57	expr "X$arg" : "X\\(.*\\)$as_nl";
58	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
59      esac;
60      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
61    '
62    export as_echo_n_body
63    as_echo_n='sh -c $as_echo_n_body as_echo'
64  fi
65  export as_echo_body
66  as_echo='sh -c $as_echo_body as_echo'
67fi
68
69# The user is always right.
70if test "${PATH_SEPARATOR+set}" != set; then
71  PATH_SEPARATOR=:
72  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
73    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
74      PATH_SEPARATOR=';'
75  }
76fi
77
78
79# IFS
80# We need space, tab and new line, in precisely that order.  Quoting is
81# there to prevent editors from complaining about space-tab.
82# (If _AS_PATH_WALK were called with IFS unset, it would disable word
83# splitting by setting IFS to empty value.)
84IFS=" ""	$as_nl"
85
86# Find who we are.  Look in the path if we contain no directory separator.
87as_myself=
88case $0 in #((
89  *[\\/]* ) as_myself=$0 ;;
90  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
91for as_dir in $PATH
92do
93  IFS=$as_save_IFS
94  test -z "$as_dir" && as_dir=.
95    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
96  done
97IFS=$as_save_IFS
98
99     ;;
100esac
101# We did not find ourselves, most probably we were run as `sh COMMAND'
102# in which case we are not to be found in the path.
103if test "x$as_myself" = x; then
104  as_myself=$0
105fi
106if test ! -f "$as_myself"; then
107  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
108  exit 1
109fi
110
111# Unset variables that we do not need and which cause bugs (e.g. in
112# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
113# suppresses any "Segmentation fault" message there.  '((' could
114# trigger a bug in pdksh 5.2.14.
115for as_var in BASH_ENV ENV MAIL MAILPATH
116do eval test x\${$as_var+set} = xset \
117  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
118done
119PS1='$ '
120PS2='> '
121PS4='+ '
122
123# NLS nuisances.
124LC_ALL=C
125export LC_ALL
126LANGUAGE=C
127export LANGUAGE
128
129# CDPATH.
130(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
131
132if test "x$CONFIG_SHELL" = x; then
133  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
134  emulate sh
135  NULLCMD=:
136  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
137  # is contrary to our usage.  Disable this feature.
138  alias -g '\${1+\"\$@\"}'='\"\$@\"'
139  setopt NO_GLOB_SUBST
140else
141  case \`(set -o) 2>/dev/null\` in #(
142  *posix*) :
143    set -o posix ;; #(
144  *) :
145     ;;
146esac
147fi
148"
149  as_required="as_fn_return () { (exit \$1); }
150as_fn_success () { as_fn_return 0; }
151as_fn_failure () { as_fn_return 1; }
152as_fn_ret_success () { return 0; }
153as_fn_ret_failure () { return 1; }
154
155exitcode=0
156as_fn_success || { exitcode=1; echo as_fn_success failed.; }
157as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
158as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
159as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
160if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
161
162else
163  exitcode=1; echo positional parameters were not saved.
164fi
165test x\$exitcode = x0 || exit 1
166test -x / || exit 1"
167  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
168  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
169  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
170  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
171test \$(( 1 + 1 )) = 2 || exit 1"
172  if (eval "$as_required") 2>/dev/null; then :
173  as_have_required=yes
174else
175  as_have_required=no
176fi
177  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
178
179else
180  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
181as_found=false
182for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
183do
184  IFS=$as_save_IFS
185  test -z "$as_dir" && as_dir=.
186  as_found=:
187  case $as_dir in #(
188	 /*)
189	   for as_base in sh bash ksh sh5; do
190	     # Try only shells that exist, to save several forks.
191	     as_shell=$as_dir/$as_base
192	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
193		    { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
194  CONFIG_SHELL=$as_shell as_have_required=yes
195		   if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
196  break 2
197fi
198fi
199	   done;;
200       esac
201  as_found=false
202done
203$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
204	      { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
205  CONFIG_SHELL=$SHELL as_have_required=yes
206fi; }
207IFS=$as_save_IFS
208
209
210      if test "x$CONFIG_SHELL" != x; then :
211  export CONFIG_SHELL
212             # We cannot yet assume a decent shell, so we have to provide a
213# neutralization value for shells without unset; and this also
214# works around shells that cannot unset nonexistent variables.
215# Preserve -v and -x to the replacement shell.
216BASH_ENV=/dev/null
217ENV=/dev/null
218(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
219case $- in # ((((
220  *v*x* | *x*v* ) as_opts=-vx ;;
221  *v* ) as_opts=-v ;;
222  *x* ) as_opts=-x ;;
223  * ) as_opts= ;;
224esac
225exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
226# Admittedly, this is quite paranoid, since all the known shells bail
227# out after a failed `exec'.
228$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
229exit 255
230fi
231
232    if test x$as_have_required = xno; then :
233  $as_echo "$0: This script requires a shell more modern than all"
234  $as_echo "$0: the shells that I found on your system."
235  if test x${ZSH_VERSION+set} = xset ; then
236    $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
237    $as_echo "$0: be upgraded to zsh 4.3.4 or later."
238  else
239    $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
240$0: including any error possibly output before this
241$0: message. Then install a modern shell, or manually run
242$0: the script under such a shell if you do have one."
243  fi
244  exit 1
245fi
246fi
247fi
248SHELL=${CONFIG_SHELL-/bin/sh}
249export SHELL
250# Unset more variables known to interfere with behavior of common tools.
251CLICOLOR_FORCE= GREP_OPTIONS=
252unset CLICOLOR_FORCE GREP_OPTIONS
253
254## --------------------- ##
255## M4sh Shell Functions. ##
256## --------------------- ##
257# as_fn_unset VAR
258# ---------------
259# Portably unset VAR.
260as_fn_unset ()
261{
262  { eval $1=; unset $1;}
263}
264as_unset=as_fn_unset
265
266# as_fn_set_status STATUS
267# -----------------------
268# Set $? to STATUS, without forking.
269as_fn_set_status ()
270{
271  return $1
272} # as_fn_set_status
273
274# as_fn_exit STATUS
275# -----------------
276# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
277as_fn_exit ()
278{
279  set +e
280  as_fn_set_status $1
281  exit $1
282} # as_fn_exit
283
284# as_fn_mkdir_p
285# -------------
286# Create "$as_dir" as a directory, including parents if necessary.
287as_fn_mkdir_p ()
288{
289
290  case $as_dir in #(
291  -*) as_dir=./$as_dir;;
292  esac
293  test -d "$as_dir" || eval $as_mkdir_p || {
294    as_dirs=
295    while :; do
296      case $as_dir in #(
297      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
298      *) as_qdir=$as_dir;;
299      esac
300      as_dirs="'$as_qdir' $as_dirs"
301      as_dir=`$as_dirname -- "$as_dir" ||
302$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
303	 X"$as_dir" : 'X\(//\)[^/]' \| \
304	 X"$as_dir" : 'X\(//\)$' \| \
305	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
306$as_echo X"$as_dir" |
307    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
308	    s//\1/
309	    q
310	  }
311	  /^X\(\/\/\)[^/].*/{
312	    s//\1/
313	    q
314	  }
315	  /^X\(\/\/\)$/{
316	    s//\1/
317	    q
318	  }
319	  /^X\(\/\).*/{
320	    s//\1/
321	    q
322	  }
323	  s/.*/./; q'`
324      test -d "$as_dir" && break
325    done
326    test -z "$as_dirs" || eval "mkdir $as_dirs"
327  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
328
329
330} # as_fn_mkdir_p
331
332# as_fn_executable_p FILE
333# -----------------------
334# Test if FILE is an executable regular file.
335as_fn_executable_p ()
336{
337  test -f "$1" && test -x "$1"
338} # as_fn_executable_p
339# as_fn_append VAR VALUE
340# ----------------------
341# Append the text in VALUE to the end of the definition contained in VAR. Take
342# advantage of any shell optimizations that allow amortized linear growth over
343# repeated appends, instead of the typical quadratic growth present in naive
344# implementations.
345if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
346  eval 'as_fn_append ()
347  {
348    eval $1+=\$2
349  }'
350else
351  as_fn_append ()
352  {
353    eval $1=\$$1\$2
354  }
355fi # as_fn_append
356
357# as_fn_arith ARG...
358# ------------------
359# Perform arithmetic evaluation on the ARGs, and store the result in the
360# global $as_val. Take advantage of shells that can avoid forks. The arguments
361# must be portable across $(()) and expr.
362if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
363  eval 'as_fn_arith ()
364  {
365    as_val=$(( $* ))
366  }'
367else
368  as_fn_arith ()
369  {
370    as_val=`expr "$@" || test $? -eq 1`
371  }
372fi # as_fn_arith
373
374
375# as_fn_error STATUS ERROR [LINENO LOG_FD]
376# ----------------------------------------
377# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
378# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
379# script with STATUS, using 1 if that was 0.
380as_fn_error ()
381{
382  as_status=$1; test $as_status -eq 0 && as_status=1
383  if test "$4"; then
384    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
385    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
386  fi
387  $as_echo "$as_me: error: $2" >&2
388  as_fn_exit $as_status
389} # as_fn_error
390
391if expr a : '\(a\)' >/dev/null 2>&1 &&
392   test "X`expr 00001 : '.*\(...\)'`" = X001; then
393  as_expr=expr
394else
395  as_expr=false
396fi
397
398if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
399  as_basename=basename
400else
401  as_basename=false
402fi
403
404as_me=`$as_basename -- "$0" ||
405$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
406	 X"$0" : 'X\(//\)$' \| \
407	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
408$as_echo X/"$0" |
409    sed '/^.*\/\([^/][^/]*\)\/*$/{
410	    s//\1/
411	    q
412	  }
413	  /^X\/\(\/\/\)$/{
414	    s//\1/
415	    q
416	  }
417	  /^X\/\(\/\).*/{
418	    s//\1/
419	    q
420	  }
421	  s/.*/./; q'`
422
423if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
424  as_dirname=dirname
425else
426  as_dirname=false
427fi
428
429# Avoid depending upon Character Ranges.
430as_cr_letters='abcdefghijklmnopqrstuvwxyz'
431as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
432as_cr_Letters=$as_cr_letters$as_cr_LETTERS
433as_cr_digits='0123456789'
434as_cr_alnum=$as_cr_Letters$as_cr_digits
435
436
437  as_lineno_1=$LINENO as_lineno_1a=$LINENO
438  as_lineno_2=$LINENO as_lineno_2a=$LINENO
439  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
440  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
441  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
442  sed -n '
443    p
444    /[$]LINENO/=
445  ' <$as_myself |
446    sed '
447      s/[$]LINENO.*/&-/
448      t lineno
449      b
450      :lineno
451      N
452      :loop
453      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
454      t loop
455      s/-\n.*//
456    ' >$as_me.lineno &&
457  chmod +x "$as_me.lineno" ||
458    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
459
460  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
461  # already done that, so ensure we don't try to do so again and fall
462  # in an infinite loop.  This has already happened in practice.
463  _as_can_reexec=no; export _as_can_reexec
464  # Don't try to exec as it changes $[0], causing all sort of problems
465  # (the dirname of $[0] is not the place where we might find the
466  # original and so on.  Autoconf is especially sensitive to this).
467  . "./$as_me.lineno"
468  # Exit status is that of the last command.
469  exit
470}
471
472ECHO_C= ECHO_N= ECHO_T=
473case `echo -n x` in #(((((
474-n*)
475  case `echo 'xy\c'` in
476  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
477  xy)  ECHO_C='\c';;
478  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
479       ECHO_T='	';;
480  esac;;
481*)
482  ECHO_N='-n';;
483esac
484
485rm -f conf$$ conf$$.exe conf$$.file
486if test -d conf$$.dir; then
487  rm -f conf$$.dir/conf$$.file
488else
489  rm -f conf$$.dir
490  mkdir conf$$.dir 2>/dev/null
491fi
492if (echo >conf$$.file) 2>/dev/null; then
493  if ln -s conf$$.file conf$$ 2>/dev/null; then
494    as_ln_s='ln -s'
495    # ... but there are two gotchas:
496    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
497    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
498    # In both cases, we have to default to `cp -pR'.
499    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
500      as_ln_s='cp -pR'
501  elif ln conf$$.file conf$$ 2>/dev/null; then
502    as_ln_s=ln
503  else
504    as_ln_s='cp -pR'
505  fi
506else
507  as_ln_s='cp -pR'
508fi
509rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
510rmdir conf$$.dir 2>/dev/null
511
512if mkdir -p . 2>/dev/null; then
513  as_mkdir_p='mkdir -p "$as_dir"'
514else
515  test -d ./-p && rmdir ./-p
516  as_mkdir_p=false
517fi
518
519as_test_x='test -x'
520as_executable_p=as_fn_executable_p
521
522# Sed expression to map a string onto a valid CPP name.
523as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525# Sed expression to map a string onto a valid variable name.
526as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529
530
531
532SHELL=${CONFIG_SHELL-/bin/sh}
533
534# How were we run?
535at_cli_args="$@"
536
537
538# Not all shells have the 'times' builtin; the subshell is needed to make
539# sure we discard the 'times: not found' message from the shell.
540at_times_p=false
541(times) >/dev/null 2>&1 && at_times_p=:
542
543# CLI Arguments to pass to the debugging scripts.
544at_debug_args=
545# -e sets to true
546at_errexit_p=false
547# Shall we be verbose?  ':' means no, empty means yes.
548at_verbose=:
549at_quiet=
550# Running several jobs in parallel, 0 means as many as test groups.
551at_jobs=1
552at_traceon=:
553at_trace_echo=:
554at_check_filter_trace=:
555
556# Shall we keep the debug scripts?  Must be `:' when the suite is
557# run by a debug script, so that the script doesn't remove itself.
558at_debug_p=false
559# Display help message?
560at_help_p=false
561# Display the version message?
562at_version_p=false
563# List test groups?
564at_list_p=false
565# --clean
566at_clean=false
567# Test groups to run
568at_groups=
569# Whether to rerun failed tests.
570at_recheck=
571# Whether a write failure occurred
572at_write_fail=0
573
574# The directory we run the suite in.  Default to . if no -C option.
575at_dir=`pwd`
576# An absolute reference to this testsuite script.
577case $as_myself in
578  [\\/]* | ?:[\\/]* ) at_myself=$as_myself ;;
579  * ) at_myself=$at_dir/$as_myself ;;
580esac
581# Whether -C is in effect.
582at_change_dir=false
583
584# Whether to enable colored test results.
585at_color=no
586# List of the tested programs.
587at_tested='readmsg'
588# As many question marks as there are digits in the last test group number.
589# Used to normalize the test group numbers so that `ls' lists them in
590# numerical order.
591at_format='?'
592# Description of all the test groups.
593at_help_all="1;testsuite.at:47;readmsg version;;
5942;all.at:17;readmsg *;readmsg00;
5953;twomsg.at:17;readmsg 1 2;twomsg;
5964;hdr.at:17;readmsg -h;hdr;
5975;nohdr.at:17;readmsg -n;nohdr;
5986;weed.at:17;readmsg -w;weed;
599"
600# List of the all the test groups.
601at_groups_all=`$as_echo "$at_help_all" | sed 's/;.*//'`
602
603# at_fn_validate_ranges NAME...
604# -----------------------------
605# Validate and normalize the test group number contained in each variable
606# NAME. Leading zeroes are treated as decimal.
607at_fn_validate_ranges ()
608{
609  for at_grp
610  do
611    eval at_value=\$$at_grp
612    if test $at_value -lt 1 || test $at_value -gt 6; then
613      $as_echo "invalid test group: $at_value" >&2
614      exit 1
615    fi
616    case $at_value in
617      0*) # We want to treat leading 0 as decimal, like expr and test, but
618	  # AS_VAR_ARITH treats it as octal if it uses $(( )).
619	  # With XSI shells, ${at_value#${at_value%%[1-9]*}} avoids the
620	  # expr fork, but it is not worth the effort to determine if the
621	  # shell supports XSI when the user can just avoid leading 0.
622	  eval $at_grp='`expr $at_value + 0`' ;;
623    esac
624  done
625}
626
627at_prev=
628for at_option
629do
630  # If the previous option needs an argument, assign it.
631  if test -n "$at_prev"; then
632    at_option=$at_prev=$at_option
633    at_prev=
634  fi
635
636  case $at_option in
637  *=?*) at_optarg=`expr "X$at_option" : '[^=]*=\(.*\)'` ;;
638  *)    at_optarg= ;;
639  esac
640
641  # Accept the important Cygnus configure options, so we can diagnose typos.
642
643  case $at_option in
644    --help | -h )
645	at_help_p=:
646	;;
647
648    --list | -l )
649	at_list_p=:
650	;;
651
652    --version | -V )
653	at_version_p=:
654	;;
655
656    --clean | -c )
657	at_clean=:
658	;;
659
660    --color )
661	at_color=always
662	;;
663    --color=* )
664	case $at_optarg in
665	no | never | none) at_color=never ;;
666	auto | tty | if-tty) at_color=auto ;;
667	always | yes | force) at_color=always ;;
668	*) at_optname=`echo " $at_option" | sed 's/^ //; s/=.*//'`
669	   as_fn_error $? "unrecognized argument to $at_optname: $at_optarg" ;;
670	esac
671	;;
672
673    --debug | -d )
674	at_debug_p=:
675	;;
676
677    --errexit | -e )
678	at_debug_p=:
679	at_errexit_p=:
680	;;
681
682    --verbose | -v )
683	at_verbose=; at_quiet=:
684	;;
685
686    --trace | -x )
687	at_traceon='set -x'
688	at_trace_echo=echo
689	at_check_filter_trace=at_fn_filter_trace
690	;;
691
692    [0-9] | [0-9][0-9] | [0-9][0-9][0-9] | [0-9][0-9][0-9][0-9])
693	at_fn_validate_ranges at_option
694	as_fn_append at_groups "$at_option$as_nl"
695	;;
696
697    # Ranges
698    [0-9]- | [0-9][0-9]- | [0-9][0-9][0-9]- | [0-9][0-9][0-9][0-9]-)
699	at_range_start=`echo $at_option |tr -d X-`
700	at_fn_validate_ranges at_range_start
701	at_range=`$as_echo "$at_groups_all" | \
702	  sed -ne '/^'$at_range_start'$/,$p'`
703	as_fn_append at_groups "$at_range$as_nl"
704	;;
705
706    -[0-9] | -[0-9][0-9] | -[0-9][0-9][0-9] | -[0-9][0-9][0-9][0-9])
707	at_range_end=`echo $at_option |tr -d X-`
708	at_fn_validate_ranges at_range_end
709	at_range=`$as_echo "$at_groups_all" | \
710	  sed -ne '1,/^'$at_range_end'$/p'`
711	as_fn_append at_groups "$at_range$as_nl"
712	;;
713
714    [0-9]-[0-9] | [0-9]-[0-9][0-9] | [0-9]-[0-9][0-9][0-9] | \
715    [0-9]-[0-9][0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9] | \
716    [0-9][0-9]-[0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9][0-9][0-9] | \
717    [0-9][0-9][0-9]-[0-9][0-9][0-9] | \
718    [0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] | \
719    [0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] )
720	at_range_start=`expr $at_option : '\(.*\)-'`
721	at_range_end=`expr $at_option : '.*-\(.*\)'`
722	if test $at_range_start -gt $at_range_end; then
723	  at_tmp=$at_range_end
724	  at_range_end=$at_range_start
725	  at_range_start=$at_tmp
726	fi
727	at_fn_validate_ranges at_range_start at_range_end
728	at_range=`$as_echo "$at_groups_all" | \
729	  sed -ne '/^'$at_range_start'$/,/^'$at_range_end'$/p'`
730	as_fn_append at_groups "$at_range$as_nl"
731	;;
732
733    # Directory selection.
734    --directory | -C )
735	at_prev=--directory
736	;;
737    --directory=* )
738	at_change_dir=:
739	at_dir=$at_optarg
740	if test x- = "x$at_dir" ; then
741	  at_dir=./-
742	fi
743	;;
744
745    # Parallel execution.
746    --jobs | -j )
747	at_jobs=0
748	;;
749    --jobs=* | -j[0-9]* )
750	if test -n "$at_optarg"; then
751	  at_jobs=$at_optarg
752	else
753	  at_jobs=`expr X$at_option : 'X-j\(.*\)'`
754	fi
755	case $at_jobs in *[!0-9]*)
756	  at_optname=`echo " $at_option" | sed 's/^ //; s/[0-9=].*//'`
757	  as_fn_error $? "non-numeric argument to $at_optname: $at_jobs" ;;
758	esac
759	;;
760
761    # Keywords.
762    --keywords | -k )
763	at_prev=--keywords
764	;;
765    --keywords=* )
766	at_groups_selected=$at_help_all
767	at_save_IFS=$IFS
768	IFS=,
769	set X $at_optarg
770	shift
771	IFS=$at_save_IFS
772	for at_keyword
773	do
774	  at_invert=
775	  case $at_keyword in
776	  '!'*)
777	    at_invert="-v"
778	    at_keyword=`expr "X$at_keyword" : 'X!\(.*\)'`
779	    ;;
780	  esac
781	  # It is on purpose that we match the test group titles too.
782	  at_groups_selected=`$as_echo "$at_groups_selected" |
783	      grep -i $at_invert "^[1-9][^;]*;.*[; ]$at_keyword[ ;]"`
784	done
785	# Smash the keywords.
786	at_groups_selected=`$as_echo "$at_groups_selected" | sed 's/;.*//'`
787	as_fn_append at_groups "$at_groups_selected$as_nl"
788	;;
789    --recheck)
790	at_recheck=:
791	;;
792
793    *=*)
794	at_envvar=`expr "x$at_option" : 'x\([^=]*\)='`
795	# Reject names that are not valid shell variable names.
796	case $at_envvar in
797	  '' | [0-9]* | *[!_$as_cr_alnum]* )
798	    as_fn_error $? "invalid variable name: \`$at_envvar'" ;;
799	esac
800	at_value=`$as_echo "$at_optarg" | sed "s/'/'\\\\\\\\''/g"`
801	# Export now, but save eval for later and for debug scripts.
802	export $at_envvar
803	as_fn_append at_debug_args " $at_envvar='$at_value'"
804	;;
805
806     *) $as_echo "$as_me: invalid option: $at_option" >&2
807	$as_echo "Try \`$0 --help' for more information." >&2
808	exit 1
809	;;
810  esac
811done
812
813# Verify our last option didn't require an argument
814if test -n "$at_prev"; then :
815  as_fn_error $? "\`$at_prev' requires an argument"
816fi
817
818# The file containing the suite.
819at_suite_log=$at_dir/$as_me.log
820
821# Selected test groups.
822if test -z "$at_groups$at_recheck"; then
823  at_groups=$at_groups_all
824else
825  if test -n "$at_recheck" && test -r "$at_suite_log"; then
826    at_oldfails=`sed -n '
827      /^Failed tests:$/,/^Skipped tests:$/{
828	s/^[ ]*\([1-9][0-9]*\):.*/\1/p
829      }
830      /^Unexpected passes:$/,/^## Detailed failed tests/{
831	s/^[ ]*\([1-9][0-9]*\):.*/\1/p
832      }
833      /^## Detailed failed tests/q
834      ' "$at_suite_log"`
835    as_fn_append at_groups "$at_oldfails$as_nl"
836  fi
837  # Sort the tests, removing duplicates.
838  at_groups=`$as_echo "$at_groups" | sort -nu | sed '/^$/d'`
839fi
840
841if test x"$at_color" = xalways \
842   || { test x"$at_color" = xauto && test -t 1; }; then
843  at_red=`printf '\033[0;31m'`
844  at_grn=`printf '\033[0;32m'`
845  at_lgn=`printf '\033[1;32m'`
846  at_blu=`printf '\033[1;34m'`
847  at_std=`printf '\033[m'`
848else
849  at_red= at_grn= at_lgn= at_blu= at_std=
850fi
851
852# Help message.
853if $at_help_p; then
854  cat <<_ATEOF || at_write_fail=1
855Usage: $0 [OPTION]... [VARIABLE=VALUE]... [TESTS]
856
857Run all the tests, or the selected TESTS, given by numeric ranges, and
858save a detailed log file.  Upon failure, create debugging scripts.
859
860Do not change environment variables directly.  Instead, set them via
861command line arguments.  Set \`AUTOTEST_PATH' to select the executables
862to exercise.  Each relative directory is expanded as build and source
863directories relative to the top level of this distribution.
864E.g., from within the build directory /tmp/foo-1.0, invoking this:
865
866  $ $0 AUTOTEST_PATH=bin
867
868is equivalent to the following, assuming the source directory is /src/foo-1.0:
869
870  PATH=/tmp/foo-1.0/bin:/src/foo-1.0/bin:\$PATH $0
871_ATEOF
872cat <<_ATEOF || at_write_fail=1
873
874Operation modes:
875  -h, --help     print the help message, then exit
876  -V, --version  print version number, then exit
877  -c, --clean    remove all the files this test suite might create and exit
878  -l, --list     describes all the tests, or the selected TESTS
879_ATEOF
880cat <<_ATEOF || at_write_fail=1
881
882Execution tuning:
883  -C, --directory=DIR
884                 change to directory DIR before starting
885      --color[=never|auto|always]
886                 enable colored test results on terminal, or always
887  -j, --jobs[=N]
888                 Allow N jobs at once; infinite jobs with no arg (default 1)
889  -k, --keywords=KEYWORDS
890                 select the tests matching all the comma-separated KEYWORDS
891                 multiple \`-k' accumulate; prefixed \`!' negates a KEYWORD
892      --recheck  select all tests that failed or passed unexpectedly last time
893  -e, --errexit  abort as soon as a test fails; implies --debug
894  -v, --verbose  force more detailed output
895                 default for debugging scripts
896  -d, --debug    inhibit clean up and top-level logging
897                 default for debugging scripts
898  -x, --trace    enable tests shell tracing
899_ATEOF
900cat <<_ATEOF || at_write_fail=1
901
902Report bugs to <bug-mailutils@gnu.org>.
903General help using GNU software: <http://www.gnu.org/gethelp/>.
904_ATEOF
905  exit $at_write_fail
906fi
907
908# List of tests.
909if $at_list_p; then
910  cat <<_ATEOF || at_write_fail=1
911GNU Mailutils 3.13 test suite test groups:
912
913 NUM: FILE-NAME:LINE     TEST-GROUP-NAME
914      KEYWORDS
915
916_ATEOF
917  # Pass an empty line as separator between selected groups and help.
918  $as_echo "$at_groups$as_nl$as_nl$at_help_all" |
919    awk 'NF == 1 && FS != ";" {
920	   selected[$ 1] = 1
921	   next
922	 }
923	 /^$/ { FS = ";" }
924	 NF > 0 {
925	   if (selected[$ 1]) {
926	     printf " %3d: %-18s %s\n", $ 1, $ 2, $ 3
927	     if ($ 4) {
928	       lmax = 79
929	       indent = "     "
930	       line = indent
931	       len = length (line)
932	       n = split ($ 4, a, " ")
933	       for (i = 1; i <= n; i++) {
934		 l = length (a[i]) + 1
935		 if (i > 1 && len + l > lmax) {
936		   print line
937		   line = indent " " a[i]
938		   len = length (line)
939		 } else {
940		   line = line " " a[i]
941		   len += l
942		 }
943	       }
944	       if (n)
945		 print line
946	     }
947	   }
948	 }' || at_write_fail=1
949  exit $at_write_fail
950fi
951if $at_version_p; then
952  $as_echo "$as_me (GNU Mailutils 3.13)" &&
953  cat <<\_ATEOF || at_write_fail=1
954
955Copyright (C) 2012 Free Software Foundation, Inc.
956This test suite is free software; the Free Software Foundation gives
957unlimited permission to copy, distribute and modify it.
958_ATEOF
959  exit $at_write_fail
960fi
961
962# Should we print banners?  Yes if more than one test is run.
963case $at_groups in #(
964  *$as_nl* )
965      at_print_banners=: ;; #(
966  * ) at_print_banners=false ;;
967esac
968# Text for banner N, set to a single space once printed.
969
970# Take any -C into account.
971if $at_change_dir ; then
972  test x != "x$at_dir" && cd "$at_dir" \
973    || as_fn_error $? "unable to change directory"
974  at_dir=`pwd`
975fi
976
977# Load the config files for any default variable assignments.
978for at_file in atconfig atlocal
979do
980  test -r $at_file || continue
981  . ./$at_file || as_fn_error $? "invalid content: $at_file"
982done
983
984# Autoconf <=2.59b set at_top_builddir instead of at_top_build_prefix:
985: "${at_top_build_prefix=$at_top_builddir}"
986
987# Perform any assignments requested during argument parsing.
988eval "$at_debug_args"
989
990# atconfig delivers names relative to the directory the test suite is
991# in, but the groups themselves are run in testsuite-dir/group-dir.
992if test -n "$at_top_srcdir"; then
993  builddir=../..
994  for at_dir_var in srcdir top_srcdir top_build_prefix
995  do
996    eval at_val=\$at_$at_dir_var
997    case $at_val in
998      [\\/$]* | ?:[\\/]* ) at_prefix= ;;
999      *) at_prefix=../../ ;;
1000    esac
1001    eval "$at_dir_var=\$at_prefix\$at_val"
1002  done
1003fi
1004
1005## -------------------- ##
1006## Directory structure. ##
1007## -------------------- ##
1008
1009# This is the set of directories and files used by this script
1010# (non-literals are capitalized):
1011#
1012# TESTSUITE         - the testsuite
1013# TESTSUITE.log     - summarizes the complete testsuite run
1014# TESTSUITE.dir/    - created during a run, remains after -d or failed test
1015# + at-groups/      - during a run: status of all groups in run
1016# | + NNN/          - during a run: meta-data about test group NNN
1017# | | + check-line  - location (source file and line) of current AT_CHECK
1018# | | + status      - exit status of current AT_CHECK
1019# | | + stdout      - stdout of current AT_CHECK
1020# | | + stder1      - stderr, including trace
1021# | | + stderr      - stderr, with trace filtered out
1022# | | + test-source - portion of testsuite that defines group
1023# | | + times       - timestamps for computing duration
1024# | | + pass        - created if group passed
1025# | | + xpass       - created if group xpassed
1026# | | + fail        - created if group failed
1027# | | + xfail       - created if group xfailed
1028# | | + skip        - created if group skipped
1029# + at-stop         - during a run: end the run if this file exists
1030# + at-source-lines - during a run: cache of TESTSUITE line numbers for extraction
1031# + 0..NNN/         - created for each group NNN, remains after -d or failed test
1032# | + TESTSUITE.log - summarizes the group results
1033# | + ...           - files created during the group
1034
1035# The directory the whole suite works in.
1036# Should be absolute to let the user `cd' at will.
1037at_suite_dir=$at_dir/$as_me.dir
1038# The file containing the suite ($at_dir might have changed since earlier).
1039at_suite_log=$at_dir/$as_me.log
1040# The directory containing helper files per test group.
1041at_helper_dir=$at_suite_dir/at-groups
1042# Stop file: if it exists, do not start new jobs.
1043at_stop_file=$at_suite_dir/at-stop
1044# The fifo used for the job dispatcher.
1045at_job_fifo=$at_suite_dir/at-job-fifo
1046
1047if $at_clean; then
1048  test -d "$at_suite_dir" &&
1049    find "$at_suite_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;
1050  rm -f -r "$at_suite_dir" "$at_suite_log"
1051  exit $?
1052fi
1053
1054# Don't take risks: use only absolute directories in PATH.
1055#
1056# For stand-alone test suites (ie. atconfig was not found),
1057# AUTOTEST_PATH is relative to `.'.
1058#
1059# For embedded test suites, AUTOTEST_PATH is relative to the top level
1060# of the package.  Then expand it into build/src parts, since users
1061# may create executables in both places.
1062AUTOTEST_PATH=`$as_echo "$AUTOTEST_PATH" | sed "s|:|$PATH_SEPARATOR|g"`
1063at_path=
1064as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1065for as_dir in $AUTOTEST_PATH $PATH
1066do
1067  IFS=$as_save_IFS
1068  test -z "$as_dir" && as_dir=.
1069    test -n "$at_path" && as_fn_append at_path $PATH_SEPARATOR
1070case $as_dir in
1071  [\\/]* | ?:[\\/]* )
1072    as_fn_append at_path "$as_dir"
1073    ;;
1074  * )
1075    if test -z "$at_top_build_prefix"; then
1076      # Stand-alone test suite.
1077      as_fn_append at_path "$as_dir"
1078    else
1079      # Embedded test suite.
1080      as_fn_append at_path "$at_top_build_prefix$as_dir$PATH_SEPARATOR"
1081      as_fn_append at_path "$at_top_srcdir/$as_dir"
1082    fi
1083    ;;
1084esac
1085  done
1086IFS=$as_save_IFS
1087
1088
1089# Now build and simplify PATH.
1090#
1091# There might be directories that don't exist, but don't redirect
1092# builtins' (eg., cd) stderr directly: Ultrix's sh hates that.
1093at_new_path=
1094as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1095for as_dir in $at_path
1096do
1097  IFS=$as_save_IFS
1098  test -z "$as_dir" && as_dir=.
1099    test -d "$as_dir" || continue
1100case $as_dir in
1101  [\\/]* | ?:[\\/]* ) ;;
1102  * ) as_dir=`(cd "$as_dir" && pwd) 2>/dev/null` ;;
1103esac
1104case $PATH_SEPARATOR$at_new_path$PATH_SEPARATOR in
1105  *$PATH_SEPARATOR$as_dir$PATH_SEPARATOR*) ;;
1106  $PATH_SEPARATOR$PATH_SEPARATOR) at_new_path=$as_dir ;;
1107  *) as_fn_append at_new_path "$PATH_SEPARATOR$as_dir" ;;
1108esac
1109  done
1110IFS=$as_save_IFS
1111
1112PATH=$at_new_path
1113export PATH
1114
1115# Setting up the FDs.
1116
1117
1118
1119# 5 is the log file.  Not to be overwritten if `-d'.
1120if $at_debug_p; then
1121  at_suite_log=/dev/null
1122else
1123  : >"$at_suite_log"
1124fi
1125exec 5>>"$at_suite_log"
1126
1127# Banners and logs.
1128$as_echo "## ------------------------------ ##
1129## GNU Mailutils 3.13 test suite. ##
1130## ------------------------------ ##"
1131{
1132  $as_echo "## ------------------------------ ##
1133## GNU Mailutils 3.13 test suite. ##
1134## ------------------------------ ##"
1135  echo
1136
1137  $as_echo "$as_me: command line was:"
1138  $as_echo "  \$ $0 $at_cli_args"
1139  echo
1140
1141  # If ChangeLog exists, list a few lines in case it might help determining
1142  # the exact version.
1143  if test -n "$at_top_srcdir" && test -f "$at_top_srcdir/ChangeLog"; then
1144    $as_echo "## ---------- ##
1145## ChangeLog. ##
1146## ---------- ##"
1147    echo
1148    sed 's/^/| /;10q' "$at_top_srcdir/ChangeLog"
1149    echo
1150  fi
1151
1152  {
1153cat <<_ASUNAME
1154## --------- ##
1155## Platform. ##
1156## --------- ##
1157
1158hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1159uname -m = `(uname -m) 2>/dev/null || echo unknown`
1160uname -r = `(uname -r) 2>/dev/null || echo unknown`
1161uname -s = `(uname -s) 2>/dev/null || echo unknown`
1162uname -v = `(uname -v) 2>/dev/null || echo unknown`
1163
1164/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1165/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1166
1167/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1168/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1169/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1170/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1171/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1172/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1173/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1174
1175_ASUNAME
1176
1177as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1178for as_dir in $PATH
1179do
1180  IFS=$as_save_IFS
1181  test -z "$as_dir" && as_dir=.
1182    $as_echo "PATH: $as_dir"
1183  done
1184IFS=$as_save_IFS
1185
1186}
1187  echo
1188
1189  # Contents of the config files.
1190  for at_file in atconfig atlocal
1191  do
1192    test -r $at_file || continue
1193    $as_echo "$as_me: $at_file:"
1194    sed 's/^/| /' $at_file
1195    echo
1196  done
1197} >&5
1198
1199# This setting is needed on FreeBSD to ensure the LD_LIBRARY_PATH overrides
1200# the DT_RPATH tag in ELF header.  See
1201# https://debbugs.gnu.org/cgi/bugreport.cgi?bug=27510
1202# for details.
1203LD_LIBRARY_PATH_RPATH=y
1204export LD_LIBRARY_PATH_RPATH
1205
1206
1207## ------------------------- ##
1208## Autotest shell functions. ##
1209## ------------------------- ##
1210
1211# at_fn_banner NUMBER
1212# -------------------
1213# Output banner NUMBER, provided the testsuite is running multiple groups and
1214# this particular banner has not yet been printed.
1215at_fn_banner ()
1216{
1217  $at_print_banners || return 0
1218  eval at_banner_text=\$at_banner_text_$1
1219  test "x$at_banner_text" = "x " && return 0
1220  eval "at_banner_text_$1=\" \""
1221  if test -z "$at_banner_text"; then
1222    $at_first || echo
1223  else
1224    $as_echo "$as_nl$at_banner_text$as_nl"
1225  fi
1226} # at_fn_banner
1227
1228# at_fn_check_prepare_notrace REASON LINE
1229# ---------------------------------------
1230# Perform AT_CHECK preparations for the command at LINE for an untraceable
1231# command; REASON is the reason for disabling tracing.
1232at_fn_check_prepare_notrace ()
1233{
1234  $at_trace_echo "Not enabling shell tracing (command contains $1)"
1235  $as_echo "$2" >"$at_check_line_file"
1236  at_check_trace=: at_check_filter=:
1237  : >"$at_stdout"; : >"$at_stderr"
1238}
1239
1240# at_fn_check_prepare_trace LINE
1241# ------------------------------
1242# Perform AT_CHECK preparations for the command at LINE for a traceable
1243# command.
1244at_fn_check_prepare_trace ()
1245{
1246  $as_echo "$1" >"$at_check_line_file"
1247  at_check_trace=$at_traceon at_check_filter=$at_check_filter_trace
1248  : >"$at_stdout"; : >"$at_stderr"
1249}
1250
1251# at_fn_check_prepare_dynamic COMMAND LINE
1252# ----------------------------------------
1253# Decide if COMMAND at LINE is traceable at runtime, and call the appropriate
1254# preparation function.
1255at_fn_check_prepare_dynamic ()
1256{
1257  case $1 in
1258    *$as_nl*)
1259      at_fn_check_prepare_notrace 'an embedded newline' "$2" ;;
1260    *)
1261      at_fn_check_prepare_trace "$2" ;;
1262  esac
1263}
1264
1265# at_fn_filter_trace
1266# ------------------
1267# Remove the lines in the file "$at_stderr" generated by "set -x" and print
1268# them to stderr.
1269at_fn_filter_trace ()
1270{
1271  mv "$at_stderr" "$at_stder1"
1272  grep '^ *+' "$at_stder1" >&2
1273  grep -v '^ *+' "$at_stder1" >"$at_stderr"
1274}
1275
1276# at_fn_log_failure FILE-LIST
1277# ---------------------------
1278# Copy the files in the list on stdout with a "> " prefix, and exit the shell
1279# with a failure exit code.
1280at_fn_log_failure ()
1281{
1282  for file
1283    do $as_echo "$file:"; sed 's/^/> /' "$file"; done
1284  echo 1 > "$at_status_file"
1285  exit 1
1286}
1287
1288# at_fn_check_skip EXIT-CODE LINE
1289# -------------------------------
1290# Check whether EXIT-CODE is a special exit code (77 or 99), and if so exit
1291# the test group subshell with that same exit code. Use LINE in any report
1292# about test failure.
1293at_fn_check_skip ()
1294{
1295  case $1 in
1296    99) echo 99 > "$at_status_file"; at_failed=:
1297	$as_echo "$2: hard failure"; exit 99;;
1298    77) echo 77 > "$at_status_file"; exit 77;;
1299  esac
1300}
1301
1302# at_fn_check_status EXPECTED EXIT-CODE LINE
1303# ------------------------------------------
1304# Check whether EXIT-CODE is the EXPECTED exit code, and if so do nothing.
1305# Otherwise, if it is 77 or 99, exit the test group subshell with that same
1306# exit code; if it is anything else print an error message referring to LINE,
1307# and fail the test.
1308at_fn_check_status ()
1309{
1310  case $2 in
1311    $1 ) ;;
1312    77) echo 77 > "$at_status_file"; exit 77;;
1313    99) echo 99 > "$at_status_file"; at_failed=:
1314	$as_echo "$3: hard failure"; exit 99;;
1315    *) $as_echo "$3: exit code was $2, expected $1"
1316      at_failed=:;;
1317  esac
1318}
1319
1320# at_fn_diff_devnull FILE
1321# -----------------------
1322# Emit a diff between /dev/null and FILE. Uses "test -s" to avoid useless diff
1323# invocations.
1324at_fn_diff_devnull ()
1325{
1326  test -s "$1" || return 0
1327  $at_diff "$at_devnull" "$1"
1328}
1329
1330# at_fn_test NUMBER
1331# -----------------
1332# Parse out test NUMBER from the tail of this file.
1333at_fn_test ()
1334{
1335  eval at_sed=\$at_sed$1
1336  sed "$at_sed" "$at_myself" > "$at_test_source"
1337}
1338
1339# at_fn_create_debugging_script
1340# -----------------------------
1341# Create the debugging script $at_group_dir/run which will reproduce the
1342# current test group.
1343at_fn_create_debugging_script ()
1344{
1345  {
1346    echo "#! /bin/sh" &&
1347    echo 'test "${ZSH_VERSION+set}" = set && alias -g '\''${1+"$@"}'\''='\''"$@"'\''' &&
1348    $as_echo "cd '$at_dir'" &&
1349    $as_echo "exec \${CONFIG_SHELL-$SHELL} \"$at_myself\" -v -d $at_debug_args $at_group \${1+\"\$@\"}" &&
1350    echo 'exit 1'
1351  } >"$at_group_dir/run" &&
1352  chmod +x "$at_group_dir/run"
1353}
1354
1355## -------------------------------- ##
1356## End of autotest shell functions. ##
1357## -------------------------------- ##
1358{
1359  $as_echo "## ---------------- ##
1360## Tested programs. ##
1361## ---------------- ##"
1362  echo
1363} >&5
1364
1365# Report what programs are being tested.
1366for at_program in : $at_tested
1367do
1368  test "$at_program" = : && continue
1369  case $at_program in
1370    [\\/]* | ?:[\\/]* ) $at_program_=$at_program ;;
1371    * )
1372    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1373for as_dir in $PATH
1374do
1375  IFS=$as_save_IFS
1376  test -z "$as_dir" && as_dir=.
1377    test -f "$as_dir/$at_program" && break
1378  done
1379IFS=$as_save_IFS
1380
1381    at_program_=$as_dir/$at_program ;;
1382  esac
1383  if test -f "$at_program_"; then
1384    {
1385      $as_echo "$at_srcdir/testsuite.at:43: $at_program_ --version"
1386      "$at_program_" --version </dev/null
1387      echo
1388    } >&5 2>&1
1389  else
1390    as_fn_error $? "cannot find $at_program" "$LINENO" 5
1391  fi
1392done
1393
1394{
1395  $as_echo "## ------------------ ##
1396## Running the tests. ##
1397## ------------------ ##"
1398} >&5
1399
1400at_start_date=`date`
1401at_start_time=`date +%s 2>/dev/null`
1402$as_echo "$as_me: starting at: $at_start_date" >&5
1403
1404# Create the master directory if it doesn't already exist.
1405as_dir="$at_suite_dir"; as_fn_mkdir_p ||
1406  as_fn_error $? "cannot create \`$at_suite_dir'" "$LINENO" 5
1407
1408# Can we diff with `/dev/null'?  DU 5.0 refuses.
1409if diff /dev/null /dev/null >/dev/null 2>&1; then
1410  at_devnull=/dev/null
1411else
1412  at_devnull=$at_suite_dir/devnull
1413  >"$at_devnull"
1414fi
1415
1416# Use `diff -u' when possible.
1417if at_diff=`diff -u "$at_devnull" "$at_devnull" 2>&1` && test -z "$at_diff"
1418then
1419  at_diff='diff -u'
1420else
1421  at_diff=diff
1422fi
1423
1424# Get the last needed group.
1425for at_group in : $at_groups; do :; done
1426
1427# Extract the start and end lines of each test group at the tail
1428# of this file
1429awk '
1430BEGIN { FS="" }
1431/^#AT_START_/ {
1432  start = NR
1433}
1434/^#AT_STOP_/ {
1435  test = substr ($ 0, 10)
1436  print "at_sed" test "=\"1," start "d;" (NR-1) "q\""
1437  if (test == "'"$at_group"'") exit
1438}' "$at_myself" > "$at_suite_dir/at-source-lines" &&
1439. "$at_suite_dir/at-source-lines" ||
1440  as_fn_error $? "cannot create test line number cache" "$LINENO" 5
1441rm -f "$at_suite_dir/at-source-lines"
1442
1443# Set number of jobs for `-j'; avoid more jobs than test groups.
1444set X $at_groups; shift; at_max_jobs=$#
1445if test $at_max_jobs -eq 0; then
1446  at_jobs=1
1447fi
1448if test $at_jobs -ne 1 &&
1449   { test $at_jobs -eq 0 || test $at_jobs -gt $at_max_jobs; }; then
1450  at_jobs=$at_max_jobs
1451fi
1452
1453# If parallel mode, don't output banners, don't split summary lines.
1454if test $at_jobs -ne 1; then
1455  at_print_banners=false
1456  at_quiet=:
1457fi
1458
1459# Set up helper dirs.
1460rm -rf "$at_helper_dir" &&
1461mkdir "$at_helper_dir" &&
1462cd "$at_helper_dir" &&
1463{ test -z "$at_groups" || mkdir $at_groups; } ||
1464as_fn_error $? "testsuite directory setup failed" "$LINENO" 5
1465
1466# Functions for running a test group.  We leave the actual
1467# test group execution outside of a shell function in order
1468# to avoid hitting zsh 4.x exit status bugs.
1469
1470# at_fn_group_prepare
1471# -------------------
1472# Prepare for running a test group.
1473at_fn_group_prepare ()
1474{
1475  # The directory for additional per-group helper files.
1476  at_job_dir=$at_helper_dir/$at_group
1477  # The file containing the location of the last AT_CHECK.
1478  at_check_line_file=$at_job_dir/check-line
1479  # The file containing the exit status of the last command.
1480  at_status_file=$at_job_dir/status
1481  # The files containing the output of the tested commands.
1482  at_stdout=$at_job_dir/stdout
1483  at_stder1=$at_job_dir/stder1
1484  at_stderr=$at_job_dir/stderr
1485  # The file containing the code for a test group.
1486  at_test_source=$at_job_dir/test-source
1487  # The file containing dates.
1488  at_times_file=$at_job_dir/times
1489
1490  # Be sure to come back to the top test directory.
1491  cd "$at_suite_dir"
1492
1493  # Clearly separate the test groups when verbose.
1494  $at_first || $at_verbose echo
1495
1496  at_group_normalized=$at_group
1497
1498  eval 'while :; do
1499    case $at_group_normalized in #(
1500    '"$at_format"'*) break;;
1501    esac
1502    at_group_normalized=0$at_group_normalized
1503  done'
1504
1505
1506  # Create a fresh directory for the next test group, and enter.
1507  # If one already exists, the user may have invoked ./run from
1508  # within that directory; we remove the contents, but not the
1509  # directory itself, so that we aren't pulling the rug out from
1510  # under the shell's notion of the current directory.
1511  at_group_dir=$at_suite_dir/$at_group_normalized
1512  at_group_log=$at_group_dir/$as_me.log
1513  if test -d "$at_group_dir"; then
1514  find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx {} \;
1515  rm -fr "$at_group_dir"/* "$at_group_dir"/.[!.] "$at_group_dir"/.??*
1516fi ||
1517    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: test directory for $at_group_normalized could not be cleaned" >&5
1518$as_echo "$as_me: WARNING: test directory for $at_group_normalized could not be cleaned" >&2;}
1519  # Be tolerant if the above `rm' was not able to remove the directory.
1520  as_dir="$at_group_dir"; as_fn_mkdir_p
1521
1522  echo 0 > "$at_status_file"
1523
1524  # In verbose mode, append to the log file *and* show on
1525  # the standard output; in quiet mode only write to the log.
1526  if test -z "$at_verbose"; then
1527    at_tee_pipe='tee -a "$at_group_log"'
1528  else
1529    at_tee_pipe='cat >> "$at_group_log"'
1530  fi
1531}
1532
1533# at_fn_group_banner ORDINAL LINE DESC PAD [BANNER]
1534# -------------------------------------------------
1535# Declare the test group ORDINAL, located at LINE with group description DESC,
1536# and residing under BANNER. Use PAD to align the status column.
1537at_fn_group_banner ()
1538{
1539  at_setup_line="$2"
1540  test -n "$5" && at_fn_banner $5
1541  at_desc="$3"
1542  case $1 in
1543    [0-9])      at_desc_line="  $1: ";;
1544    [0-9][0-9]) at_desc_line=" $1: " ;;
1545    *)          at_desc_line="$1: "  ;;
1546  esac
1547  as_fn_append at_desc_line "$3$4"
1548  $at_quiet $as_echo_n "$at_desc_line"
1549  echo "#                             -*- compilation -*-" >> "$at_group_log"
1550}
1551
1552# at_fn_group_postprocess
1553# -----------------------
1554# Perform cleanup after running a test group.
1555at_fn_group_postprocess ()
1556{
1557  # Be sure to come back to the suite directory, in particular
1558  # since below we might `rm' the group directory we are in currently.
1559  cd "$at_suite_dir"
1560
1561  if test ! -f "$at_check_line_file"; then
1562    sed "s/^ */$as_me: WARNING: /" <<_ATEOF
1563      A failure happened in a test group before any test could be
1564      run. This means that test suite is improperly designed.  Please
1565      report this failure to <bug-mailutils@gnu.org>.
1566_ATEOF
1567    $as_echo "$at_setup_line" >"$at_check_line_file"
1568    at_status=99
1569  fi
1570  $at_verbose $as_echo_n "$at_group. $at_setup_line: "
1571  $as_echo_n "$at_group. $at_setup_line: " >> "$at_group_log"
1572  case $at_xfail:$at_status in
1573    yes:0)
1574	at_msg="UNEXPECTED PASS"
1575	at_res=xpass
1576	at_errexit=$at_errexit_p
1577	at_color=$at_red
1578	;;
1579    no:0)
1580	at_msg="ok"
1581	at_res=pass
1582	at_errexit=false
1583	at_color=$at_grn
1584	;;
1585    *:77)
1586	at_msg='skipped ('`cat "$at_check_line_file"`')'
1587	at_res=skip
1588	at_errexit=false
1589	at_color=$at_blu
1590	;;
1591    no:* | *:99)
1592	at_msg='FAILED ('`cat "$at_check_line_file"`')'
1593	at_res=fail
1594	at_errexit=$at_errexit_p
1595	at_color=$at_red
1596	;;
1597    yes:*)
1598	at_msg='expected failure ('`cat "$at_check_line_file"`')'
1599	at_res=xfail
1600	at_errexit=false
1601	at_color=$at_lgn
1602	;;
1603  esac
1604  echo "$at_res" > "$at_job_dir/$at_res"
1605  # In parallel mode, output the summary line only afterwards.
1606  if test $at_jobs -ne 1 && test -n "$at_verbose"; then
1607    $as_echo "$at_desc_line $at_color$at_msg$at_std"
1608  else
1609    # Make sure there is a separator even with long titles.
1610    $as_echo " $at_color$at_msg$at_std"
1611  fi
1612  at_log_msg="$at_group. $at_desc ($at_setup_line): $at_msg"
1613  case $at_status in
1614    0|77)
1615      # $at_times_file is only available if the group succeeded.
1616      # We're not including the group log, so the success message
1617      # is written in the global log separately.  But we also
1618      # write to the group log in case they're using -d.
1619      if test -f "$at_times_file"; then
1620	at_log_msg="$at_log_msg     ("`sed 1d "$at_times_file"`')'
1621	rm -f "$at_times_file"
1622      fi
1623      $as_echo "$at_log_msg" >> "$at_group_log"
1624      $as_echo "$at_log_msg" >&5
1625
1626      # Cleanup the group directory, unless the user wants the files
1627      # or the success was unexpected.
1628      if $at_debug_p || test $at_res = xpass; then
1629	at_fn_create_debugging_script
1630	if test $at_res = xpass && $at_errexit; then
1631	  echo stop > "$at_stop_file"
1632	fi
1633      else
1634	if test -d "$at_group_dir"; then
1635	  find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;
1636	  rm -fr "$at_group_dir"
1637	fi
1638	rm -f "$at_test_source"
1639      fi
1640      ;;
1641    *)
1642      # Upon failure, include the log into the testsuite's global
1643      # log.  The failure message is written in the group log.  It
1644      # is later included in the global log.
1645      $as_echo "$at_log_msg" >> "$at_group_log"
1646
1647      # Upon failure, keep the group directory for autopsy, and create
1648      # the debugging script.  With -e, do not start any further tests.
1649      at_fn_create_debugging_script
1650      if $at_errexit; then
1651	echo stop > "$at_stop_file"
1652      fi
1653      ;;
1654  esac
1655}
1656
1657
1658## ------------ ##
1659## Driver loop. ##
1660## ------------ ##
1661
1662
1663if (set -m && set +m && set +b) >/dev/null 2>&1; then
1664  set +b
1665  at_job_control_on='set -m' at_job_control_off='set +m' at_job_group=-
1666else
1667  at_job_control_on=: at_job_control_off=: at_job_group=
1668fi
1669
1670for at_signal in 1 2 15; do
1671  trap 'set +x; set +e
1672	$at_job_control_off
1673	at_signal='"$at_signal"'
1674	echo stop > "$at_stop_file"
1675	trap "" $at_signal
1676	at_pgids=
1677	for at_pgid in `jobs -p 2>/dev/null`; do
1678	  at_pgids="$at_pgids $at_job_group$at_pgid"
1679	done
1680	test -z "$at_pgids" || kill -$at_signal $at_pgids 2>/dev/null
1681	wait
1682	if test "$at_jobs" -eq 1 || test -z "$at_verbose"; then
1683	  echo >&2
1684	fi
1685	at_signame=`kill -l $at_signal 2>&1 || echo $at_signal`
1686	set x $at_signame
1687	test 0 -gt 2 && at_signame=$at_signal
1688	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: caught signal $at_signame, bailing out" >&5
1689$as_echo "$as_me: WARNING: caught signal $at_signame, bailing out" >&2;}
1690	as_fn_arith 128 + $at_signal && exit_status=$as_val
1691	as_fn_exit $exit_status' $at_signal
1692done
1693
1694rm -f "$at_stop_file"
1695at_first=:
1696
1697if test $at_jobs -ne 1 &&
1698     rm -f "$at_job_fifo" &&
1699     test -n "$at_job_group" &&
1700     ( mkfifo "$at_job_fifo" && trap 'exit 1' PIPE STOP TSTP ) 2>/dev/null
1701then
1702  # FIFO job dispatcher.
1703
1704  trap 'at_pids=
1705	for at_pid in `jobs -p`; do
1706	  at_pids="$at_pids $at_job_group$at_pid"
1707	done
1708	if test -n "$at_pids"; then
1709	  at_sig=TSTP
1710	  test "${TMOUT+set}" = set && at_sig=STOP
1711	  kill -$at_sig $at_pids 2>/dev/null
1712	fi
1713	kill -STOP $$
1714	test -z "$at_pids" || kill -CONT $at_pids 2>/dev/null' TSTP
1715
1716  echo
1717  # Turn jobs into a list of numbers, starting from 1.
1718  at_joblist=`$as_echo "$at_groups" | sed -n 1,${at_jobs}p`
1719
1720  set X $at_joblist
1721  shift
1722  for at_group in $at_groups; do
1723    $at_job_control_on 2>/dev/null
1724    (
1725      # Start one test group.
1726      $at_job_control_off
1727      if $at_first; then
1728	exec 7>"$at_job_fifo"
1729      else
1730	exec 6<&-
1731      fi
1732      trap 'set +x; set +e
1733	    trap "" PIPE
1734	    echo stop > "$at_stop_file"
1735	    echo >&7
1736	    as_fn_exit 141' PIPE
1737      at_fn_group_prepare
1738      if cd "$at_group_dir" &&
1739	 at_fn_test $at_group &&
1740	 . "$at_test_source"
1741      then :; else
1742	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unable to parse test group: $at_group" >&5
1743$as_echo "$as_me: WARNING: unable to parse test group: $at_group" >&2;}
1744	at_failed=:
1745      fi
1746      at_fn_group_postprocess
1747      echo >&7
1748    ) &
1749    $at_job_control_off
1750    if $at_first; then
1751      at_first=false
1752      exec 6<"$at_job_fifo" 7>"$at_job_fifo"
1753    fi
1754    shift # Consume one token.
1755    if test $# -gt 0; then :; else
1756      read at_token <&6 || break
1757      set x $*
1758    fi
1759    test -f "$at_stop_file" && break
1760  done
1761  exec 7>&-
1762  # Read back the remaining ($at_jobs - 1) tokens.
1763  set X $at_joblist
1764  shift
1765  if test $# -gt 0; then
1766    shift
1767    for at_job
1768    do
1769      read at_token
1770    done <&6
1771  fi
1772  exec 6<&-
1773  wait
1774else
1775  # Run serially, avoid forks and other potential surprises.
1776  for at_group in $at_groups; do
1777    at_fn_group_prepare
1778    if cd "$at_group_dir" &&
1779       at_fn_test $at_group &&
1780       . "$at_test_source"; then :; else
1781      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unable to parse test group: $at_group" >&5
1782$as_echo "$as_me: WARNING: unable to parse test group: $at_group" >&2;}
1783      at_failed=:
1784    fi
1785    at_fn_group_postprocess
1786    test -f "$at_stop_file" && break
1787    at_first=false
1788  done
1789fi
1790
1791# Wrap up the test suite with summary statistics.
1792cd "$at_helper_dir"
1793
1794# Use ?..???? when the list must remain sorted, the faster * otherwise.
1795at_pass_list=`for f in */pass; do echo $f; done | sed '/\*/d; s,/pass,,'`
1796at_skip_list=`for f in */skip; do echo $f; done | sed '/\*/d; s,/skip,,'`
1797at_xfail_list=`for f in */xfail; do echo $f; done | sed '/\*/d; s,/xfail,,'`
1798at_xpass_list=`for f in ?/xpass ??/xpass ???/xpass ????/xpass; do
1799		 echo $f; done | sed '/?/d; s,/xpass,,'`
1800at_fail_list=`for f in ?/fail ??/fail ???/fail ????/fail; do
1801		echo $f; done | sed '/?/d; s,/fail,,'`
1802
1803set X $at_pass_list $at_xpass_list $at_xfail_list $at_fail_list $at_skip_list
1804shift; at_group_count=$#
1805set X $at_xpass_list; shift; at_xpass_count=$#; at_xpass_list=$*
1806set X $at_xfail_list; shift; at_xfail_count=$#
1807set X $at_fail_list; shift; at_fail_count=$#; at_fail_list=$*
1808set X $at_skip_list; shift; at_skip_count=$#
1809
1810as_fn_arith $at_group_count - $at_skip_count && at_run_count=$as_val
1811as_fn_arith $at_xpass_count + $at_fail_count && at_unexpected_count=$as_val
1812as_fn_arith $at_xfail_count + $at_fail_count && at_total_fail_count=$as_val
1813
1814# Back to the top directory.
1815cd "$at_dir"
1816rm -rf "$at_helper_dir"
1817
1818# Compute the duration of the suite.
1819at_stop_date=`date`
1820at_stop_time=`date +%s 2>/dev/null`
1821$as_echo "$as_me: ending at: $at_stop_date" >&5
1822case $at_start_time,$at_stop_time in
1823  [0-9]*,[0-9]*)
1824    as_fn_arith $at_stop_time - $at_start_time && at_duration_s=$as_val
1825    as_fn_arith $at_duration_s / 60 && at_duration_m=$as_val
1826    as_fn_arith $at_duration_m / 60 && at_duration_h=$as_val
1827    as_fn_arith $at_duration_s % 60 && at_duration_s=$as_val
1828    as_fn_arith $at_duration_m % 60 && at_duration_m=$as_val
1829    at_duration="${at_duration_h}h ${at_duration_m}m ${at_duration_s}s"
1830    $as_echo "$as_me: test suite duration: $at_duration" >&5
1831    ;;
1832esac
1833
1834echo
1835$as_echo "## ------------- ##
1836## Test results. ##
1837## ------------- ##"
1838echo
1839{
1840  echo
1841  $as_echo "## ------------- ##
1842## Test results. ##
1843## ------------- ##"
1844  echo
1845} >&5
1846
1847if test $at_run_count = 1; then
1848  at_result="1 test"
1849  at_were=was
1850else
1851  at_result="$at_run_count tests"
1852  at_were=were
1853fi
1854if $at_errexit_p && test $at_unexpected_count != 0; then
1855  if test $at_xpass_count = 1; then
1856    at_result="$at_result $at_were run, one passed"
1857  else
1858    at_result="$at_result $at_were run, one failed"
1859  fi
1860  at_result="$at_result unexpectedly and inhibited subsequent tests."
1861  at_color=$at_red
1862else
1863  # Don't you just love exponential explosion of the number of cases?
1864  at_color=$at_red
1865  case $at_xpass_count:$at_fail_count:$at_xfail_count in
1866    # So far, so good.
1867    0:0:0) at_result="$at_result $at_were successful." at_color=$at_grn ;;
1868    0:0:*) at_result="$at_result behaved as expected." at_color=$at_lgn ;;
1869
1870    # Some unexpected failures
1871    0:*:0) at_result="$at_result $at_were run,
1872$at_fail_count failed unexpectedly." ;;
1873
1874    # Some failures, both expected and unexpected
1875    0:*:1) at_result="$at_result $at_were run,
1876$at_total_fail_count failed ($at_xfail_count expected failure)." ;;
1877    0:*:*) at_result="$at_result $at_were run,
1878$at_total_fail_count failed ($at_xfail_count expected failures)." ;;
1879
1880    # No unexpected failures, but some xpasses
1881    *:0:*) at_result="$at_result $at_were run,
1882$at_xpass_count passed unexpectedly." ;;
1883
1884    # No expected failures, but failures and xpasses
1885    *:1:0) at_result="$at_result $at_were run,
1886$at_unexpected_count did not behave as expected ($at_fail_count unexpected failure)." ;;
1887    *:*:0) at_result="$at_result $at_were run,
1888$at_unexpected_count did not behave as expected ($at_fail_count unexpected failures)." ;;
1889
1890    # All of them.
1891    *:*:1) at_result="$at_result $at_were run,
1892$at_xpass_count passed unexpectedly,
1893$at_total_fail_count failed ($at_xfail_count expected failure)." ;;
1894    *:*:*) at_result="$at_result $at_were run,
1895$at_xpass_count passed unexpectedly,
1896$at_total_fail_count failed ($at_xfail_count expected failures)." ;;
1897  esac
1898
1899  if test $at_skip_count = 0 && test $at_run_count -gt 1; then
1900    at_result="All $at_result"
1901  fi
1902fi
1903
1904# Now put skips in the mix.
1905case $at_skip_count in
1906  0) ;;
1907  1) at_result="$at_result
19081 test was skipped." ;;
1909  *) at_result="$at_result
1910$at_skip_count tests were skipped." ;;
1911esac
1912
1913if test $at_unexpected_count = 0; then
1914  echo "$at_color$at_result$at_std"
1915  echo "$at_result" >&5
1916else
1917  echo "${at_color}ERROR: $at_result$at_std" >&2
1918  echo "ERROR: $at_result" >&5
1919  {
1920    echo
1921    $as_echo "## ------------------------ ##
1922## Summary of the failures. ##
1923## ------------------------ ##"
1924
1925    # Summary of failed and skipped tests.
1926    if test $at_fail_count != 0; then
1927      echo "Failed tests:"
1928      $SHELL "$at_myself" $at_fail_list --list
1929      echo
1930    fi
1931    if test $at_skip_count != 0; then
1932      echo "Skipped tests:"
1933      $SHELL "$at_myself" $at_skip_list --list
1934      echo
1935    fi
1936    if test $at_xpass_count != 0; then
1937      echo "Unexpected passes:"
1938      $SHELL "$at_myself" $at_xpass_list --list
1939      echo
1940    fi
1941    if test $at_fail_count != 0; then
1942      $as_echo "## ---------------------- ##
1943## Detailed failed tests. ##
1944## ---------------------- ##"
1945      echo
1946      for at_group in $at_fail_list
1947      do
1948	at_group_normalized=$at_group
1949
1950  eval 'while :; do
1951    case $at_group_normalized in #(
1952    '"$at_format"'*) break;;
1953    esac
1954    at_group_normalized=0$at_group_normalized
1955  done'
1956
1957	cat "$at_suite_dir/$at_group_normalized/$as_me.log"
1958	echo
1959      done
1960      echo
1961    fi
1962    if test -n "$at_top_srcdir"; then
1963      sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
1964## ${at_top_build_prefix}config.log ##
1965_ASBOX
1966      sed 's/^/| /' ${at_top_build_prefix}config.log
1967      echo
1968    fi
1969  } >&5
1970
1971  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
1972## $as_me.log was created. ##
1973_ASBOX
1974
1975  echo
1976  if $at_debug_p; then
1977    at_msg='per-test log files'
1978  else
1979    at_msg="\`${at_testdir+${at_testdir}/}$as_me.log'"
1980  fi
1981  $as_echo "Please send $at_msg and all information you think might help:
1982
1983   To: <bug-mailutils@gnu.org>
1984   Subject: [GNU Mailutils 3.13] $as_me: $at_fail_list${at_fail_list:+ failed${at_xpass_list:+, }}$at_xpass_list${at_xpass_list:+ passed unexpectedly}
1985
1986You may investigate any problem if you feel able to do so, in which
1987case the test suite provides a good starting point.  Its output may
1988be found below \`${at_testdir+${at_testdir}/}$as_me.dir'.
1989"
1990  exit 1
1991fi
1992
1993exit 0
1994
1995## ------------- ##
1996## Actual tests. ##
1997## ------------- ##
1998#AT_START_1
1999at_fn_group_banner 1 'testsuite.at:47' \
2000  "readmsg version" "                                "
2001at_xfail=no
2002(
2003  $as_echo "1. $at_setup_line: testing $at_desc ..."
2004  $at_traceon
2005
2006
2007{ set +x
2008$as_echo "$at_srcdir/testsuite.at:47: readmsg --version | sed '1{s/-[0-9][0-9]* //;s/ *\\[.*\\]//;q;}' "
2009at_fn_check_prepare_notrace 'a shell pipeline' "testsuite.at:47"
2010( $at_check_trace; readmsg --version | sed '1{s/-[0-9][0-9]* //;s/ *\[.*\]//;q;}'
2011) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2012at_status=$? at_failed=false
2013$at_check_filter
2014at_fn_diff_devnull "$at_stderr" || at_failed=:
2015echo >>"$at_stdout"; $as_echo "readmsg (GNU Mailutils) 3.13
2016" | \
2017  $at_diff - "$at_stdout" || at_failed=:
2018at_fn_check_status 0 $at_status "$at_srcdir/testsuite.at:47"
2019$at_failed && at_fn_log_failure
2020$at_traceon; }
2021
2022
2023  set +x
2024  $at_times_p && times >"$at_times_file"
2025) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2026read at_status <"$at_status_file"
2027#AT_STOP_1
2028#AT_START_2
2029at_fn_group_banner 2 'all.at:17' \
2030  "readmsg *" "                                      "
2031at_xfail=no
2032(
2033  $as_echo "2. $at_setup_line: testing $at_desc ..."
2034  $at_traceon
2035
2036
2037{ set +x
2038$as_echo "$at_srcdir/all.at:17:
2039MAIL=\$abs_top_srcdir/testsuite/spool/mbox1
2040FOLDER=\$MAIL
2041export MAIL FOLDER
2042readmsg --no-site --no-user '*'"
2043at_fn_check_prepare_notrace 'an embedded newline' "all.at:17"
2044( $at_check_trace;
2045MAIL=$abs_top_srcdir/testsuite/spool/mbox1
2046FOLDER=$MAIL
2047export MAIL FOLDER
2048readmsg --no-site --no-user '*'
2049) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2050at_status=$? at_failed=false
2051$at_check_filter
2052at_fn_diff_devnull "$at_stderr" || at_failed=:
2053echo >>"$at_stdout"; $as_echo "Date: Fri, 28 Dec 2001 22:18:08 +0200
2054From: Foo Bar <foobar@nonexistent.net>
2055To: Bar <bar@dontmailme.org>
2056Subject: Jabberwocky
2057
2058\`Twas brillig, and the slithy toves
2059Did gyre and gimble in the wabe;
2060All mimsy were the borogoves,
2061And the mome raths outgrabe.
2062
2063\`Beware the Jabberwock, my son!
2064The jaws that bite, the claws that catch!
2065Beware the Jujub bird, and shun
2066The frumious Bandersnatch!'
2067
2068He took his vorpal sword in hand:
2069Long time the manxome foe he sought --
2070So rested he by the Tumtum gree,
2071And stood awhile in thought.
2072
2073And as in uffish thought he stood,
2074The Jabberwock, with eyes of flame,
2075Came whiffling through the tulgey wook,
2076And burbled as it came!
2077
2078One, two!  One, two!  And through and through
2079The vorpal blade went snicker-snack!
2080He left it dead, and with its head
2081He went galumphing back.
2082
2083\`And has thou slain the Jabberwock?
2084Come to my arms, my beamish boy!
2085O frabjous day!  Calloh!  Callay!
2086He chortled in his joy.
2087
2088\`Twas brillig, and the slithy toves
2089Did gyre and gimble in the wabe;
2090All mimsy were the borogoves,
2091And the mome raths outgrabe.
2092
2093
2094
2095Date: Fri, 28 Dec 2001 23:28:08 +0200
2096From: Bar <bar@dontmailme.org>
2097To: Foo Bar <foobar@nonexistent.net>
2098Subject: Re: Jabberwocky
2099
2100It seems very pretty, but it's *rather* hard to understand!'
2101Somehow it seems to fill my head with ideas -- only I don't
2102exactly know what they are!  However, SOMEBODY killed SOMETHING:
2103that's clear, at any rate...
2104
2105
2106To: Foo Bar <foobar@nonexistent.net>
2107Subject: Simple MIME
2108Date: Sat, 13 Jul 2002 00:43:18 +0300
2109From: Sergey Poznyakoff <gray@example.net>
2110
2111------- =_aaaaaaaaaa0
2112Content-Type: text/plain; name=\"msg.1\"; charset=\"us-ascii\"
2113Content-ID: <5082.1026510189.1@example.net>
2114Content-Description: How doth
2115
2116How doth the little crocodile
2117Improve his shining tail,
2118And pour the waters of the Nile
2119On every golden scale!
2120
2121\`How cheerfully he seems to grin,
2122How neatly spread his claws,
2123And welcome little fishes in
2124With gently smiling jaws!
2125
2126------- =_aaaaaaaaaa0
2127Content-Type: application/octet-stream; name=\"msg.21\"
2128Content-ID: <5082.1026510189.2@example.net>
2129Content-Description: Father William Part I
2130Content-Transfer-Encoding: base64
2131
2132YFlvdSBhcmUgb2xkLCBGYXRoZXIgV2lsbGlhbSwnIHRoZSB5b3VuZyBtYW4gc2FpZCwKYEFuZCB5
2133b3VyIGhhaXIgaGFzIGJlY29tZSB2ZXJ5IHdoaXRlOwpBbmQgeWV0IHlvdSBpbmNlc3NhbnRseSBz
2134dGFuZCBvbiB5b3VyIGhlYWQtLQpEbyB5b3UgdGhpbmssIGF0IHlvdXIgYWdlLCBpdCBpcyByaWdo
2135dD8nCgpgSW4gbXkgeW91dGgsJyBGYXRoZXIgV2lsbGlhbSByZXBsaWVkIHRvIGhpcyBzb24sCmBJ
2136IGZlYXJlZCBpdCBtaWdodCBpbmp1cmUgdGhlIGJyYWluOwpCdXQsIG5vdyB0aGF0IEknbSBwZXJm
2137ZWN0bHkgc3VyZSBJIGhhdmUgbm9uZSwKV2h5LCBJIGRvIGl0IGFnYWluIGFuZCBhZ2Fpbi4nCgo=
2138
2139------- =_aaaaaaaaaa0--
2140
2141
2142To: Foo Bar <foobar@nonexistent.net>
2143Subject: Nested MIME
2144Date: Sat, 13 Jul 2002 00:50:58 +0300
2145From: Sergey Poznyakoff <gray@example.net>
2146
2147------- =_aaaaaaaaaa0
2148Content-Type: text/plain; name=\"msg.21\"; charset=\"us-ascii\"
2149Content-ID: <5122.1026510654.2@example.net>
2150Content-Description: Father William Part I
2151
2152\`You are old, Father William,' the young man said,
2153\`And your hair has become very white;
2154And yet you incessantly stand on your head--
2155Do you think, at your age, it is right?'
2156
2157\`In my youth,' Father William replied to his son,
2158\`I feared it might injure the brain;
2159But, now that I'm perfectly sure I have none,
2160Why, I do it again and again.'
2161
2162
2163------- =_aaaaaaaaaa0
2164Content-Type: multipart/mixed; boundary=\"----- =_aaaaaaaaaa1\"
2165Content-ID: <5122.1026510654.3@example.net>
2166
2167------- =_aaaaaaaaaa1
2168Content-Type: application/octet-stream; name=\"msg.22\"
2169Content-ID: <5122.1026510654.4@example.net>
2170Content-Description: Father William Part II
2171Content-Transfer-Encoding: base64
2172
2173YFlvdSBhcmUgb2xkLCcgc2FpZCB0aGUgeW91dGgsIGBhcyBJIG1lbnRpb25lZCBiZWZvcmUsCkFu
2174ZCBoYXZlIGdyb3duIG1vc3QgdW5jb21tb25seSBmYXQ7CllldCB5b3UgdHVybmVkIGEgYmFjay1z
2175b21lcnNhdWx0IGluIGF0IHRoZSBkb29yLS0KUHJheSwgd2hhdCBpcyB0aGUgcmVhc29uIG9mIHRo
2176YXQ/JwoKYEluIG15IHlvdXRoLCcgc2FpZCB0aGUgc2FnZSwgYXMgaGUgc2hvb2sgaGlzIGdyZXkg
2177bG9ja3MsCmBJIGtlcHQgYWxsIG15IGxpbWJzIHZlcnkgc3VwcGxlCkJ5IHRoZSB1c2Ugb2YgdGhp
2178cyBvaW50bWVudC0tb25lIHNoaWxsaW5nIHRoZSBib3gtLQpBbGxvdyBtZSB0byBzZWxsIHlvdSBh
2179IGNvdXBsZT8nCg==
2180
2181------- =_aaaaaaaaaa1
2182Content-Type: multipart/mixed; boundary=\"----- =_aaaaaaaaaa2\"
2183Content-ID: <5122.1026510654.5@example.net>
2184
2185------- =_aaaaaaaaaa2
2186Content-Type: application/octet-stream; name=\"msg.23\"
2187Content-ID: <5122.1026510654.6@example.net>
2188Content-Description: Father William Part III
2189Content-Transfer-Encoding: base64
2190
2191YFlvdSBhcmUgb2xkLCcgc2FpZCB0aGUgeW91dGgsIGBhbmQgeW91ciBqYXdzIGFyZSB0b28gd2Vh
2192awpGb3IgYW55dGhpbmcgdG91Z2hlciB0aGFuIHN1ZXQ7CllldCB5b3UgZmluaXNoZWQgdGhlIGdv
2193b3NlLCB3aXRoIHRoZSBib25lcyBhbmQgdGhlIGJlYWstLQpQcmF5IGhvdyBkaWQgeW91IG1hbmFn
2194ZSB0byBkbyBpdD8nCgpgSW4gbXkgeW91dGgsJyBzYWlkIGhpcyBmYXRoZXIsIGBJIHRvb2sgdG8g
2195dGhlIGxhdywKQW5kIGFyZ3VlZCBlYWNoIGNhc2Ugd2l0aCBteSB3aWZlOwpBbmQgdGhlIG11c2N1
2196bGFyIHN0cmVuZ3RoLCB3aGljaCBpdCBnYXZlIHRvIG15IGphdywKSGFzIGxhc3RlZCB0aGUgcmVz
2197dCBvZiBteSBsaWZlLicK
2198
2199------- =_aaaaaaaaaa2
2200Content-Type: application/octet-stream; name=\"msg.24\"
2201Content-ID: <5122.1026510654.7@example.net>
2202Content-Description: Father William Part IV
2203Content-Transfer-Encoding: base64
2204
2205YFlvdSBhcmUgb2xkLCcgc2FpZCB0aGUgeW91dGgsIGBvbmUgd291bGQgaGFyZGx5IHN1cHBvc2UK
2206VGhhdCB5b3VyIGV5ZSB3YXMgYXMgc3RlYWR5IGFzIGV2ZXI7CllldCB5b3UgYmFsYW5jZWQgYW4g
2207ZWVsIG9uIHRoZSBlbmQgb2YgeW91ciBub3NlLS0KV2hhdCBtYWRlIHlvdSBzbyBhd2Z1bGx5IGNs
2208ZXZlcj8nCgpgSSBoYXZlIGFuc3dlcmVkIHRocmVlIHF1ZXN0aW9ucywgYW5kIHRoYXQgaXMgZW5v
2209dWdoLCcKU2FpZCBoaXMgZmF0aGVyOyBgZG9uJ3QgZ2l2ZSB5b3Vyc2VsZiBhaXJzIQpEbyB5b3Ug
2210dGhpbmsgSSBjYW4gbGlzdGVuIGFsbCBkYXkgdG8gc3VjaCBzdHVmZj8KQmUgb2ZmLCBvciBJJ2xs
2211IGtpY2sgeW91IGRvd24gc3RhaXJzIScK
2212
2213------- =_aaaaaaaaaa2--
2214
2215------- =_aaaaaaaaaa1--
2216
2217------- =_aaaaaaaaaa0--
2218
2219
2220To: Foo Bar <foobar@nonexistent.net>
2221Subject: Empty MIME Parts
2222Date: Sat, 13 Jul 2002 00:43:18 +0300
2223From: Sergey Poznyakoff <gray@example.net>
2224
2225------- =_aaaaaaaaaa0
2226Content-Type: text/plain; name=\"empty\"; charset=\"us-ascii\"
2227Content-ID: <5082.1026510189.1@example.net>
2228Content-Description: Empty part
2229
2230
2231------- =_aaaaaaaaaa0
2232Content-Type: text/plain; name=\"single.line\"; charset=\"us-ascii\"
2233Content-ID: <5082.1026510189.2@example.net>
2234Content-Description: Single line part
2235
2236
2237
2238------- =_aaaaaaaaaa0--
2239
2240
2241" | \
2242  $at_diff - "$at_stdout" || at_failed=:
2243at_fn_check_status 0 $at_status "$at_srcdir/all.at:17"
2244$at_failed && at_fn_log_failure
2245$at_traceon; }
2246
2247  set +x
2248  $at_times_p && times >"$at_times_file"
2249) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2250read at_status <"$at_status_file"
2251#AT_STOP_2
2252#AT_START_3
2253at_fn_group_banner 3 'twomsg.at:17' \
2254  "readmsg 1 2" "                                    "
2255at_xfail=no
2256(
2257  $as_echo "3. $at_setup_line: testing $at_desc ..."
2258  $at_traceon
2259
2260
2261{ set +x
2262$as_echo "$at_srcdir/twomsg.at:17:
2263MAIL=\$abs_top_srcdir/testsuite/spool/mbox1
2264FOLDER=\$MAIL
2265export MAIL FOLDER
2266readmsg --no-site --no-user 1 2"
2267at_fn_check_prepare_notrace 'an embedded newline' "twomsg.at:17"
2268( $at_check_trace;
2269MAIL=$abs_top_srcdir/testsuite/spool/mbox1
2270FOLDER=$MAIL
2271export MAIL FOLDER
2272readmsg --no-site --no-user 1 2
2273) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2274at_status=$? at_failed=false
2275$at_check_filter
2276at_fn_diff_devnull "$at_stderr" || at_failed=:
2277echo >>"$at_stdout"; $as_echo "Date: Fri, 28 Dec 2001 22:18:08 +0200
2278From: Foo Bar <foobar@nonexistent.net>
2279To: Bar <bar@dontmailme.org>
2280Subject: Jabberwocky
2281
2282\`Twas brillig, and the slithy toves
2283Did gyre and gimble in the wabe;
2284All mimsy were the borogoves,
2285And the mome raths outgrabe.
2286
2287\`Beware the Jabberwock, my son!
2288The jaws that bite, the claws that catch!
2289Beware the Jujub bird, and shun
2290The frumious Bandersnatch!'
2291
2292He took his vorpal sword in hand:
2293Long time the manxome foe he sought --
2294So rested he by the Tumtum gree,
2295And stood awhile in thought.
2296
2297And as in uffish thought he stood,
2298The Jabberwock, with eyes of flame,
2299Came whiffling through the tulgey wook,
2300And burbled as it came!
2301
2302One, two!  One, two!  And through and through
2303The vorpal blade went snicker-snack!
2304He left it dead, and with its head
2305He went galumphing back.
2306
2307\`And has thou slain the Jabberwock?
2308Come to my arms, my beamish boy!
2309O frabjous day!  Calloh!  Callay!
2310He chortled in his joy.
2311
2312\`Twas brillig, and the slithy toves
2313Did gyre and gimble in the wabe;
2314All mimsy were the borogoves,
2315And the mome raths outgrabe.
2316
2317
2318
2319Date: Fri, 28 Dec 2001 23:28:08 +0200
2320From: Bar <bar@dontmailme.org>
2321To: Foo Bar <foobar@nonexistent.net>
2322Subject: Re: Jabberwocky
2323
2324It seems very pretty, but it's *rather* hard to understand!'
2325Somehow it seems to fill my head with ideas -- only I don't
2326exactly know what they are!  However, SOMEBODY killed SOMETHING:
2327that's clear, at any rate...
2328
2329
2330
2331" | \
2332  $at_diff - "$at_stdout" || at_failed=:
2333at_fn_check_status 0 $at_status "$at_srcdir/twomsg.at:17"
2334$at_failed && at_fn_log_failure
2335$at_traceon; }
2336
2337  set +x
2338  $at_times_p && times >"$at_times_file"
2339) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2340read at_status <"$at_status_file"
2341#AT_STOP_3
2342#AT_START_4
2343at_fn_group_banner 4 'hdr.at:17' \
2344  "readmsg -h" "                                     "
2345at_xfail=no
2346(
2347  $as_echo "4. $at_setup_line: testing $at_desc ..."
2348  $at_traceon
2349
2350
2351{ set +x
2352$as_echo "$at_srcdir/hdr.at:17:
2353MAIL=\$abs_top_srcdir/testsuite/spool/mbox1
2354FOLDER=\$MAIL
2355export MAIL FOLDER
2356readmsg --no-site --no-user readmsg -h SOMETHING"
2357at_fn_check_prepare_notrace 'an embedded newline' "hdr.at:17"
2358( $at_check_trace;
2359MAIL=$abs_top_srcdir/testsuite/spool/mbox1
2360FOLDER=$MAIL
2361export MAIL FOLDER
2362readmsg --no-site --no-user readmsg -h SOMETHING
2363) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2364at_status=$? at_failed=false
2365$at_check_filter
2366at_fn_diff_devnull "$at_stderr" || at_failed=:
2367echo >>"$at_stdout"; $as_echo "From bar@dontmailme.org Fri Dec 28 23:28:09 2001
2368Received: (from bar@dontmailme.org)
2369	by dontmailme.org id fERKR9N16790
2370	for foobar@nonexistent.net; Fri, 28 Dec 2001 22:18:08 +0200
2371Date: Fri, 28 Dec 2001 23:28:08 +0200
2372From: Bar <bar@dontmailme.org>
2373To: Foo Bar <foobar@nonexistent.net>
2374Message-Id: <200112232808.fERKR9N16790@dontmailme.org>
2375Subject: Re: Jabberwocky
2376
2377It seems very pretty, but it's *rather* hard to understand!'
2378Somehow it seems to fill my head with ideas -- only I don't
2379exactly know what they are!  However, SOMEBODY killed SOMETHING:
2380that's clear, at any rate...
2381
2382
2383
2384" | \
2385  $at_diff - "$at_stdout" || at_failed=:
2386at_fn_check_status 0 $at_status "$at_srcdir/hdr.at:17"
2387$at_failed && at_fn_log_failure
2388$at_traceon; }
2389
2390  set +x
2391  $at_times_p && times >"$at_times_file"
2392) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2393read at_status <"$at_status_file"
2394#AT_STOP_4
2395#AT_START_5
2396at_fn_group_banner 5 'nohdr.at:17' \
2397  "readmsg -n" "                                     "
2398at_xfail=no
2399(
2400  $as_echo "5. $at_setup_line: testing $at_desc ..."
2401  $at_traceon
2402
2403
2404{ set +x
2405$as_echo "$at_srcdir/nohdr.at:17:
2406MAIL=\$abs_top_srcdir/testsuite/spool/mbox1
2407FOLDER=\$MAIL
2408export MAIL FOLDER
2409readmsg --no-site --no-user readmsg -n SOMETHING"
2410at_fn_check_prepare_notrace 'an embedded newline' "nohdr.at:17"
2411( $at_check_trace;
2412MAIL=$abs_top_srcdir/testsuite/spool/mbox1
2413FOLDER=$MAIL
2414export MAIL FOLDER
2415readmsg --no-site --no-user readmsg -n SOMETHING
2416) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2417at_status=$? at_failed=false
2418$at_check_filter
2419at_fn_diff_devnull "$at_stderr" || at_failed=:
2420echo >>"$at_stdout"; $as_echo "It seems very pretty, but it's *rather* hard to understand!'
2421Somehow it seems to fill my head with ideas -- only I don't
2422exactly know what they are!  However, SOMEBODY killed SOMETHING:
2423that's clear, at any rate...
2424
2425
2426
2427" | \
2428  $at_diff - "$at_stdout" || at_failed=:
2429at_fn_check_status 0 $at_status "$at_srcdir/nohdr.at:17"
2430$at_failed && at_fn_log_failure
2431$at_traceon; }
2432
2433  set +x
2434  $at_times_p && times >"$at_times_file"
2435) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2436read at_status <"$at_status_file"
2437#AT_STOP_5
2438#AT_START_6
2439at_fn_group_banner 6 'weed.at:17' \
2440  "readmsg -w" "                                     "
2441at_xfail=no
2442(
2443  $as_echo "6. $at_setup_line: testing $at_desc ..."
2444  $at_traceon
2445
2446
2447{ set +x
2448$as_echo "$at_srcdir/weed.at:17:
2449MAIL=\$abs_top_srcdir/testsuite/spool/mbox1
2450FOLDER=\$MAIL
2451export MAIL FOLDER
2452readmsg --no-site --no-user -w date,subject SOMETHING"
2453at_fn_check_prepare_notrace 'an embedded newline' "weed.at:17"
2454( $at_check_trace;
2455MAIL=$abs_top_srcdir/testsuite/spool/mbox1
2456FOLDER=$MAIL
2457export MAIL FOLDER
2458readmsg --no-site --no-user -w date,subject SOMETHING
2459) >>"$at_stdout" 2>>"$at_stderr" 5>&-
2460at_status=$? at_failed=false
2461$at_check_filter
2462at_fn_diff_devnull "$at_stderr" || at_failed=:
2463echo >>"$at_stdout"; $as_echo "Date: Fri, 28 Dec 2001 23:28:08 +0200
2464Subject: Re: Jabberwocky
2465
2466It seems very pretty, but it's *rather* hard to understand!'
2467Somehow it seems to fill my head with ideas -- only I don't
2468exactly know what they are!  However, SOMEBODY killed SOMETHING:
2469that's clear, at any rate...
2470
2471
2472
2473" | \
2474  $at_diff - "$at_stdout" || at_failed=:
2475at_fn_check_status 0 $at_status "$at_srcdir/weed.at:17"
2476$at_failed && at_fn_log_failure
2477$at_traceon; }
2478
2479  set +x
2480  $at_times_p && times >"$at_times_file"
2481) 5>&1 2>&1 7>&- | eval $at_tee_pipe
2482read at_status <"$at_status_file"
2483#AT_STOP_6
2484