mirror of
https://github.com/postgres/postgres.git
synced 2025-06-05 23:56:58 +03:00
Fix back-branch pg_regress scripts to try the "canonical" expected file if we
tried a variant file from resultmap and it didn't match. This is already done in HEAD's C-code version, and is needed because OpenBSD has recently migrated to a more standard handling of float underflow --- see buildfarm results from emu.
This commit is contained in:
parent
e407ca3a7b
commit
b7edacccbe
@ -1,5 +1,5 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
# $PostgreSQL: pgsql/src/test/regress/pg_regress.sh,v 1.61 2005/11/01 15:09:11 adunstan Exp $
|
# $PostgreSQL: pgsql/src/test/regress/pg_regress.sh,v 1.61.2.1 2006/10/09 01:45:41 tgl Exp $
|
||||||
|
|
||||||
me=`basename $0`
|
me=`basename $0`
|
||||||
: ${TMPDIR=/tmp}
|
: ${TMPDIR=/tmp}
|
||||||
@ -675,7 +675,8 @@ do
|
|||||||
# to a system-specific expected file.
|
# to a system-specific expected file.
|
||||||
# There shouldn't be multiple matches, but take the last if there are.
|
# There shouldn't be multiple matches, but take the last if there are.
|
||||||
|
|
||||||
EXPECTED="$inputdir/expected/${name}"
|
STDEXPECTED="$inputdir/expected/${name}"
|
||||||
|
EXPECTED="$STDEXPECTED"
|
||||||
for LINE in $SUBSTLIST
|
for LINE in $SUBSTLIST
|
||||||
do
|
do
|
||||||
if [ `expr "$LINE" : "$name="` -ne 0 ]
|
if [ `expr "$LINE" : "$name="` -ne 0 ]
|
||||||
@ -685,13 +686,14 @@ do
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# If there are multiple equally valid result files, loop to get the right one.
|
# If there are multiple equally valid result files,
|
||||||
|
# loop to get the right one.
|
||||||
# If none match, diff against the closest one.
|
# If none match, diff against the closest one.
|
||||||
|
|
||||||
bestfile=
|
bestfile=
|
||||||
bestdiff=
|
bestdiff=
|
||||||
result=2
|
result=2
|
||||||
for thisfile in $EXPECTED.out ${EXPECTED}_[0-9].out; do
|
for thisfile in $EXPECTED.out ${EXPECTED}_[0-9].out $STDEXPECTED.out; do
|
||||||
[ ! -r "$thisfile" ] && continue
|
[ ! -r "$thisfile" ] && continue
|
||||||
diff $DIFFFLAGS $thisfile $outputdir/results/${name}.out >/dev/null 2>&1
|
diff $DIFFFLAGS $thisfile $outputdir/results/${name}.out >/dev/null 2>&1
|
||||||
result=$?
|
result=$?
|
||||||
|
Loading…
x
Reference in New Issue
Block a user