Skip to content

Commit b535e2b

Browse files
committed
test/tiff2ps*.sh scripts: try to use POSIX only diff flags
1 parent 95911a1 commit b535e2b

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

test/tiff2ps-EPS1.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,7 @@
55
PSFILE=o-tiff2ps-EPS1.ps
66
. ${srcdir:-.}/common.sh
77
f_test_stdout "${TIFF2PS} -e -1" "${IMG_MINISWHITE_1C_1B}" "${PSFILE}"
8-
diff -Z -I '%%CreationDate:.*' -I '%%Title:.*' -u "${REFS}/${PSFILE}" "${PSFILE}" || exit 1
8+
cat "${REFS}/${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.ref.tmp"
9+
cat "${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.tmp"
10+
diff -b -u "${PSFILE}.ref.tmp" "${PSFILE}.tmp" || exit 1
11+
rm -f "${PSFILE}.ref.tmp" "${PSFILE}.tmp"

test/tiff2ps-PS1.sh

+4-2
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,7 @@
55
PSFILE="o-tiff2ps-PS1.ps"
66
. ${srcdir:-.}/common.sh
77
f_test_stdout "${TIFF2PS} -a -p -1" "${IMG_MINISWHITE_1C_1B}" "${PSFILE}"
8-
#diff -I '%%(CreationDate|Title):.*' -u "${REFS}/${PSFILE}" "${PSFILE}" || exit 1
9-
diff -Z -I '%%CreationDate:.*' -I '%%Title:.*' -u "${REFS}/${PSFILE}" "${PSFILE}" || exit 1
8+
cat "${REFS}/${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.ref.tmp"
9+
cat "${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.tmp"
10+
diff -b -u "${PSFILE}.ref.tmp" "${PSFILE}.tmp" || exit 1
11+
rm -f "${PSFILE}.ref.tmp" "${PSFILE}.tmp"

test/tiff2ps-PS2.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,7 @@
55
PSFILE=o-tiff2ps-PS2.ps
66
. ${srcdir:-.}/common.sh
77
f_test_stdout "${TIFF2PS} -a -p -2" "${IMG_MINISWHITE_1C_1B}" "${PSFILE}"
8-
diff -Z -I '%%CreationDate:.*' -I '%%Title:.*' -u "${REFS}/${PSFILE}" "${PSFILE}" || exit 1
8+
cat "${REFS}/${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.ref.tmp"
9+
cat "${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.tmp"
10+
diff -b -u "${PSFILE}.ref.tmp" "${PSFILE}.tmp" || exit 1
11+
rm -f "${PSFILE}.ref.tmp" "${PSFILE}.tmp"

test/tiff2ps-PS3.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,7 @@
55
PSFILE=o-tiff2ps-PS3.ps
66
. ${srcdir:-.}/common.sh
77
f_test_stdout "${TIFF2PS} -a -p -3" "${IMG_MINISWHITE_1C_1B}" "${PSFILE}"
8-
diff -Z -I '%%CreationDate:.*' -I '%%Title:.*' -u "${REFS}/${PSFILE}" "${PSFILE}" || exit 1
8+
cat "${REFS}/${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.ref.tmp"
9+
cat "${PSFILE}" | grep -v '%%CreationDate:' | grep -v '%%Title:' > "${PSFILE}.tmp"
10+
diff -b -u "${PSFILE}.ref.tmp" "${PSFILE}.tmp" || exit 1
11+
rm -f "${PSFILE}.ref.tmp" "${PSFILE}.tmp"

0 commit comments

Comments
 (0)