From: Josh Coalson Date: Fri, 30 Jul 2004 00:22:46 +0000 (+0000) Subject: add testing of min/max possible --skip values X-Git-Tag: 1.2.0~787 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=29f52ea9db5062e8c136976fb16bbb9f889c9023;p=platform%2Fupstream%2Fflac.git add testing of min/max possible --skip values --- diff --git a/test/test_flac.sh b/test/test_flac.sh index f1b6c6f..0454d93 100755 --- a/test/test_flac.sh +++ b/test/test_flac.sh @@ -509,6 +509,27 @@ if [ $has_ogg = "yes" ] ; then test_skip_until aiff ogg fi +echo "Testing seek extremes:" + +run_flac --verify --force --silent --force-raw-format --endian=big --sign=signed --sample-rate=44100 --bps=16 --channels=2 --blocksize=576 noise.raw || die "ERROR generating FLAC file" + +total_samples=`metaflac --show-total-samples noise.flac` +[ $? = 0 ] || die "ERROR getting total sample count from noise.flac" + +echo -n "Testing --skip=0... " +run_flac $wav_dopt --skip=0 -o z.wav noise.flac || die "ERROR decoding FLAC file $desc" +echo OK + +for delta in 2 1 ; do + n=`expr $total_samples - $delta` + echo -n "Testing --skip=$n... " + run_flac $wav_dopt --skip=$n -o z.wav noise.flac || die "ERROR decoding FLAC file $desc" + echo OK +done + +rm noise.flac z.wav + + ############################################################################ # test --cue ############################################################################