summaryrefslogtreecommitdiffstats
path: root/intel/tests/test-batch.sh
diff options
context:
space:
mode:
Diffstat (limited to 'intel/tests/test-batch.sh')
-rwxr-xr-xintel/tests/test-batch.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/intel/tests/test-batch.sh b/intel/tests/test-batch.sh
new file mode 100755
index 0000000..b85f639
--- /dev/null
+++ b/intel/tests/test-batch.sh
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+TEST_FILENAME=`echo "$0" | sed 's|\.sh$||'`
+./test_decode $TEST_FILENAME
+
+ret=$?
+
+# pretty-print a diff showing what happened, and leave the dumped
+# around for possibly moving over the ref.
+if test $ret = 1; then
+ REF_FILENAME="$TEST_FILENAME-ref.txt"
+ NEW_FILENAME="$TEST_FILENAME-new.txt"
+ ./test_decode $TEST_FILENAME -dump > $NEW_FILENAME
+ if test $? = 0; then
+ echo "Differences:"
+ diff -u $REF_FILENAME $NEW_FILENAME
+ fi
+fi
+
+exit $ret