diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-13 04:09:21 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-19 00:13:40 +0200 |
commit | 277306f54bb6d0927a793dec5a7c09ae47648359 (patch) | |
tree | 9dc5abd8eb288f35d16d8083d0660b875dce3bc1 /tests/fate-run.sh | |
parent | e1d9bfc3ee3ce52ab976052e3019b41dd798553a (diff) | |
download | ffmpeg-277306f54bb6d0927a793dec5a7c09ae47648359.tar.gz |
fate: Allow to test temporary files with ffprobe
This is primarily intended to test that muxers correctly write chapters
or metadata; but given that it does this by having our demuxers read the
generated files, it also tests demuxers. And of course it may prove
useful for encoders, too.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'tests/fate-run.sh')
-rwxr-xr-x | tests/fate-run.sh | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/tests/fate-run.sh b/tests/fate-run.sh index 552b3dd9df..7c6d753261 100755 --- a/tests/fate-run.sh +++ b/tests/fate-run.sh @@ -192,6 +192,7 @@ enc_dec(){ enc_opt=$4 dec_fmt=$5 dec_opt=$6 + ffprobe_opts=$9 encfile="${outdir}/${test}.${enc_fmt}" decfile="${outdir}/${test}.out.${dec_fmt}" cleanfiles="$cleanfiles $decfile" @@ -207,6 +208,8 @@ enc_dec(){ -f $dec_fmt -y $tdecfile || return do_md5sum $decfile tests/tiny_psnr${HOSTEXECSUF} $srcfile $decfile $cmp_unit $cmp_shift + test -z $ffprobe_opts || \ + run ffprobe${PROGSUF}${EXECSUF} $ffprobe_opts -v 0 $tencfile || return } transcode(){ @@ -215,8 +218,9 @@ transcode(){ enc_fmt=$3 enc_opt=$4 final_decode=$5 + ffprobe_opts=$7 encfile="${outdir}/${test}.${enc_fmt}" - test "$7" = -keep || cleanfiles="$cleanfiles $encfile" + test "$6" = -keep || cleanfiles="$cleanfiles $encfile" tsrcfile=$(target_path $srcfile) tencfile=$(target_path $encfile) ffmpeg -f $src_fmt $DEC_OPTS -i $tsrcfile $ENC_OPTS $enc_opt $FLAGS \ @@ -225,6 +229,8 @@ transcode(){ echo $(wc -c $encfile) ffmpeg $DEC_OPTS -i $tencfile $ENC_OPTS $FLAGS $final_decode \ -f framecrc - || return + test -z $ffprobe_opts || \ + run ffprobe${PROGSUF}${EXECSUF} $ffprobe_opts -v 0 $tencfile || return } stream_remux(){ @@ -233,14 +239,17 @@ stream_remux(){ enc_fmt=$3 stream_maps=$4 final_decode=$5 + ffprobe_opts=$7 encfile="${outdir}/${test}.${enc_fmt}" - test "$7" = -keep || cleanfiles="$cleanfiles $encfile" + test "$6" = -keep || cleanfiles="$cleanfiles $encfile" tsrcfile=$(target_path $srcfile) tencfile=$(target_path $encfile) ffmpeg -f $src_fmt -i $tsrcfile $stream_maps -codec copy $FLAGS \ -f $enc_fmt -y $tencfile || return ffmpeg $DEC_OPTS -i $tencfile $ENC_OPTS $FLAGS $final_decode \ -f framecrc - || return + test -z $ffprobe_opts || \ + run ffprobe${PROGSUF}${EXECSUF} $ffprobe_opts -v 0 $tencfile || return } # FIXME: There is a certain duplication between the avconv-related helper |