| 77 |
|
|
| 78 |
# Find the test data |
# Find the test data |
| 79 |
|
|
|
testdata=testdata |
|
| 80 |
if [ -n "$srcdir" -a -d "$srcdir" ] ; then |
if [ -n "$srcdir" -a -d "$srcdir" ] ; then |
| 81 |
testdata="$srcdir/testdata" |
testdata="$srcdir/testdata" |
| 82 |
|
elif [ -d "./testdata" ] ; then |
| 83 |
|
testdata=./testdata |
| 84 |
|
elif [ -d "../testdata" ] ; then |
| 85 |
|
testdata=../testdata |
| 86 |
|
else |
| 87 |
|
echo "Cannot find the testdata directory" |
| 88 |
|
exit 1 |
| 89 |
fi |
fi |
| 90 |
|
|
| 91 |
# Find which optional facilities are available |
# Find which optional facilities are available |
| 192 |
do15=yes |
do15=yes |
| 193 |
fi |
fi |
| 194 |
|
|
| 195 |
# Show which release |
# Show which release and which test data |
| 196 |
|
|
| 197 |
echo "" |
echo "" |
| 198 |
echo PCRE C library tests |
echo PCRE C library tests using test data from $testdata |
| 199 |
./pcretest /dev/null |
$sim ./pcretest /dev/null |
| 200 |
|
|
| 201 |
# Primary test, compatible with JIT and all versions of Perl >= 5.8 |
# Primary test, compatible with JIT and all versions of Perl >= 5.8 |
| 202 |
|
|
| 243 |
|
|
| 244 |
# Locale-specific tests, provided that either the "fr_FR" or the "french" |
# Locale-specific tests, provided that either the "fr_FR" or the "french" |
| 245 |
# locale is available. The former is the Unix-like standard; the latter is |
# locale is available. The former is the Unix-like standard; the latter is |
| 246 |
# for Windows. |
# for Windows. Another possibility is "fr", which needs to be run against |
| 247 |
|
# the Windows-specific input and output files. |
| 248 |
|
|
| 249 |
if [ $do3 = yes ] ; then |
if [ $do3 = yes ] ; then |
| 250 |
locale -a | grep '^fr_FR$' >/dev/null |
locale -a | grep '^fr_FR$' >/dev/null |
| 253 |
infile=$testdata/testinput3 |
infile=$testdata/testinput3 |
| 254 |
outfile=$testdata/testoutput3 |
outfile=$testdata/testoutput3 |
| 255 |
else |
else |
| 256 |
|
infile=test3input |
| 257 |
|
outfile=test3output |
| 258 |
locale -a | grep '^french$' >/dev/null |
locale -a | grep '^french$' >/dev/null |
| 259 |
if [ $? -eq 0 ] ; then |
if [ $? -eq 0 ] ; then |
| 260 |
locale=french |
locale=french |
| 261 |
sed 's/fr_FR/french/' $testdata/testinput3 >test3input |
sed 's/fr_FR/french/' $testdata/testinput3 >test3input |
| 262 |
sed 's/fr_FR/french/' $testdata/testoutput3 >test3output |
sed 's/fr_FR/french/' $testdata/testoutput3 >test3output |
|
infile=test3input |
|
|
outfile=test3output |
|
| 263 |
else |
else |
| 264 |
locale= |
locale -a | grep '^fr$' >/dev/null |
| 265 |
|
if [ $? -eq 0 ] ; then |
| 266 |
|
locale=fr |
| 267 |
|
sed 's/fr_FR/fr/' $testdata/wintestinput3 >test3input |
| 268 |
|
sed 's/fr_FR/fr/' $testdata/wintestoutput3 >test3output |
| 269 |
|
else |
| 270 |
|
locale= |
| 271 |
|
fi |
| 272 |
fi |
fi |
| 273 |
fi |
fi |
| 274 |
|
|