tests: misc/printf: accommodate alternate behavior

* tests/misc/printf: Avoid false positive failure on MacOS X 10.5
due to a slightly differing diagnostic.  Reported by Bruno Haible.
This commit is contained in:
Jim Meyering 2011-09-01 12:14:11 +02:00
parent a8c7983629
commit ac54e1e4d2

View File

@ -110,6 +110,11 @@ cat <<EOF > exp
0
EOF
# POSIX says strtoimax *may* set errno to EINVAL in the latter
# two cases. So far, that happens at least on MacOS X 10.5.
# Map that output to the more common expected output.
sed 's/: Invalid.*/: expected a numeric value/' err > k && mv k err
cat <<EOF > exp_err
printf: warning: ": character(s) following character constant have been ignored
printf: ": expected a numeric value