summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rwxr-xr-xtests/fate-run.sh9
2 files changed, 8 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index fe39154829..efb714f6c0 100644
--- a/Makefile
+++ b/Makefile
@@ -281,7 +281,7 @@ ifdef SAMPLES
fate: $(FATE_TESTS)
$(FATE_TESTS): ffmpeg$(EXESUF)
@echo "TEST FATE $(@:fate-%=%)"
- @$(SRC_PATH)/tests/fate-run.sh $@ "$(SAMPLES)" "$(TARGET_EXEC)" "$(TARGET_PATH)" '$(CMD)'
+ @$(SRC_PATH)/tests/fate-run.sh $@ "$(SAMPLES)" "$(TARGET_EXEC)" "$(TARGET_PATH)" '$(CMD)' '$(CMP)' '$(REF)' '$(FUZZ)'
else
fate $(FATE_TESTS):
@echo "SAMPLES not specified, cannot run FATE"
diff --git a/tests/fate-run.sh b/tests/fate-run.sh
index 899580fa71..39f42ffcc3 100755
--- a/tests/fate-run.sh
+++ b/tests/fate-run.sh
@@ -8,12 +8,17 @@ SAMPLES_PATH=$2
target_exec=$3
BUILD_PATH=$4
command=$5
+cmp=${6:-diff}
-ref="${base}/ref/fate/${test}"
+ref=${7:-"${base}/ref/fate/${test}"}
+fuzz=$8
outdir="tests/data/fate"
outfile="${outdir}/${test}"
mkdir -p "$outdir"
eval $target_exec $command > "$outfile" 2>/dev/null
-diff -u -w "$ref" "$outfile"
+
+case $cmp in
+ diff) diff -u -w "$ref" "$outfile" ;;
+esac