From d219e87e72e1a08796cf2bc567d0c2d17f2e807c Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sun, 9 Apr 2000 07:33:52 +0000 Subject: [PATCH] . --- tests/date/Makefile.am | 4 ++-- tests/date/Makefile.in | 4 ++-- tests/date/date-tests | 20 +++++++++++++++++++- 3 files changed, 23 insertions(+), 5 deletions(-) diff --git a/tests/date/Makefile.am b/tests/date/Makefile.am index e7a9f2679b..3d7dc3ed13 100644 --- a/tests/date/Makefile.am +++ b/tests/date/Makefile.am @@ -10,7 +10,7 @@ rel-2d.X rel-2e.X rel-2f.X rel-2g.X rel-3a.X next-s.X next-m.X next-h.X \ next-d.X next-w.X next-mo.X next-y.X utc-0.X utc-0a.X utc-1.I utc-1.X \ utc-1a.I utc-1a.X date2sec-0.X date2sec-0a.X date2sec-1.X sec2date-0.X \ this-m.X this-h.X this-w.X this-mo.X this-y.X risks-1.X regress-1.X \ -datevtime-1.X +datevtime-1.X rfc822-1.X run_gen = 1.O 1.E 2.O 2.E 3.O 3.E 4.O 4.E 5.O 5.E 6.O 6.E 7.O 7.E 8.O 8.E 9.O \ 9.E leap-1.O leap-1.E U95-1.O U95-1.E U95-2.O U95-2.E U95-3.O U95-3.E U92-1.O \ U92-1.E U92-2.O U92-2.E U92-3.O U92-3.E V92-1.O V92-1.E V92-2.O V92-2.E \ @@ -24,7 +24,7 @@ utc-0a.E utc-1.O utc-1.E utc-1a.O utc-1a.E date2sec-0.O date2sec-0.E \ date2sec-0a.O date2sec-0a.E date2sec-1.O date2sec-1.E sec2date-0.O \ sec2date-0.E this-m.O this-m.E this-h.O this-h.E this-w.O this-w.E this-mo.O \ this-mo.E this-y.O this-y.E risks-1.O risks-1.E regress-1.O regress-1.E \ -datevtime-1.O datevtime-1.E +datevtime-1.O datevtime-1.E rfc822-1.O rfc822-1.E ##test-files-end EXTRA_DIST = Test.pm $x-tests $(explicit) $(maint_gen) diff --git a/tests/date/Makefile.in b/tests/date/Makefile.in index e8b4e8e9ef..4f02144831 100644 --- a/tests/date/Makefile.in +++ b/tests/date/Makefile.in @@ -123,7 +123,7 @@ rel-2d.X rel-2e.X rel-2f.X rel-2g.X rel-3a.X next-s.X next-m.X next-h.X \ next-d.X next-w.X next-mo.X next-y.X utc-0.X utc-0a.X utc-1.I utc-1.X \ utc-1a.I utc-1a.X date2sec-0.X date2sec-0a.X date2sec-1.X sec2date-0.X \ this-m.X this-h.X this-w.X this-mo.X this-y.X risks-1.X regress-1.X \ -datevtime-1.X +datevtime-1.X rfc822-1.X run_gen = 1.O 1.E 2.O 2.E 3.O 3.E 4.O 4.E 5.O 5.E 6.O 6.E 7.O 7.E 8.O 8.E 9.O \ 9.E leap-1.O leap-1.E U95-1.O U95-1.E U95-2.O U95-2.E U95-3.O U95-3.E U92-1.O \ @@ -138,7 +138,7 @@ utc-0a.E utc-1.O utc-1.E utc-1a.O utc-1a.E date2sec-0.O date2sec-0.E \ date2sec-0a.O date2sec-0a.E date2sec-1.O date2sec-1.E sec2date-0.O \ sec2date-0.E this-m.O this-m.E this-h.O this-h.E this-w.O this-w.E this-mo.O \ this-mo.E this-y.O this-y.E risks-1.O risks-1.E regress-1.O regress-1.E \ -datevtime-1.O datevtime-1.E +datevtime-1.O datevtime-1.E rfc822-1.O rfc822-1.E EXTRA_DIST = Test.pm $x-tests $(explicit) $(maint_gen) diff --git a/tests/date/date-tests b/tests/date/date-tests index b8cc548285..aed6e9bd91 100755 --- a/tests/date/date-tests +++ b/tests/date/date-tests @@ -1044,8 +1044,26 @@ else esac fi test -s datevtime-1.E || rm -f datevtime-1.E +LC_ALL=de_DE $xx -R -d '1997-01-19 08:17:48 +0' > rfc822-1.O 2> rfc822-1.E +code=$? +if test $code != 0; then + $echo "Test rfc822-1(LC_ALL=de_DE) failed: ../../src/date return code $code differs from expected value 0" 1>&2 + errors=`expr $errors + 1` +else + cmp rfc822-1.O $srcdir/rfc822-1.X > /dev/null 2>&1 + case $? in + 0) if test "$VERBOSE"; then $echo "passed rfc822-1(LC_ALL=de_DE)"; fi;; + 1) $echo "Test rfc822-1(LC_ALL=de_DE) failed: files rfc822-1.O and $srcdir/rfc822-1.X differ" 1>&2 + (diff -c rfc822-1.O $srcdir/rfc822-1.X) 2> /dev/null + errors=`expr $errors + 1`;; + 2) $echo "Test rfc822-1(LC_ALL=de_DE) may have failed." 1>&2 + $echo The command "cmp rfc822-1.O $srcdir/rfc822-1.X" failed. 1>&2 + errors=`expr $errors + 1`;; + esac +fi +test -s rfc822-1.E || rm -f rfc822-1.E if test $errors = 0; then - $echo Passed all 57 tests. 1>&2 + $echo Passed all 58 tests. 1>&2 else $echo Failed $errors tests. 1>&2 fi -- 2.39.5