copycooker.sh 688 B

123456789101112131415161718192021222324252627282930
  1. #!/bin/sh
  2. LC_ALL=C
  3. export LC_ALL
  4. datadir="tests/data"
  5. logfile="$datadir/copy.regression"
  6. reffile="$1"
  7. list=$(grep -oh ' ./tests/data/.*' tests/ref/{acodec,lavf,vsynth1}/*| sort)
  8. rm -f $logfile
  9. for i in $list ; do
  10. echo ---------------- >> $logfile
  11. echo $i >> $logfile
  12. ./ffmpeg_g -flags +bitexact -i $i -acodec copy -vcodec copy -y first.nut
  13. ./ffmpeg_g -flags +bitexact -i first.nut -acodec copy -vcodec copy -y second.nut
  14. cmp first.nut second.nut >> $logfile
  15. md5sum first.nut >> $logfile
  16. done
  17. if diff -u -w "$reffile" "$logfile" ; then
  18. echo
  19. echo copy regression test: success
  20. exit 0
  21. else
  22. echo
  23. echo copy regression test: error
  24. exit 1
  25. fi