Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1234)

Unified Diff: testing/tools/make_expected.sh

Issue 1264873005: Add simple script to regenerate expected results. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: testing/tools/make_expected.sh
diff --git a/testing/tools/make_expected.sh b/testing/tools/make_expected.sh
new file mode 100755
index 0000000000000000000000000000000000000000..282d41611c71fb777ba6340e82384754d235c44b
--- /dev/null
+++ b/testing/tools/make_expected.sh
@@ -0,0 +1,15 @@
+#!/bin/bash
+#
+# Script to generate expected result files.
+#
+
+while (( "$#" )); do
+ INFILE="$1"
+ out/Debug/pdfium_test --png $INFILE
+ RESULTS="$INFILE.*.png"
+ for RESULT in $RESULTS ; do
Lei Zhang 2015/07/30 21:18:16 This won't work correctly if there's spaces in fil
+ EXPECTED=`echo -n $RESULT | sed 's/[.]pdf[.]/_expected.pdf./'`
+ mv $RESULT $EXPECTED
+ done
+ shift
+done
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698