Chris@155: #!/bin/bash Chris@155: Chris@155: . ../include.sh Chris@155: Chris@155: infile=$audiopath/20sec-silence.wav Chris@156: tmpcsv=$mypath/tmp_1_$$.csv Chris@155: Chris@156: trap "rm -f $tmpcsv" 0 Chris@155: Chris@207: for output in notes-regions curve-vsr grid-oss; do Chris@155: Chris@155: flag="" Chris@155: Chris@156: $r -d "$testplug:$output" -w csv --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@155: fail "Failed to run for plugin $testplug with output $output and no additional flags" Chris@155: Chris@156: csvcompare "$tmpcsv" "$mypath/expected/$output-no-flags.csv" || \ Chris@156: faildiff "Output differs from expected for output $output and no additional flags" "$tmpcsv" "$mypath/expected/$output-no-flags.csv" Chris@155: Chris@156: flag=sample-timing Chris@155: Chris@156: $r -d "$testplug:$output" -w csv --csv-$flag --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@155: fail "Failed to run for plugin $testplug with output $output and $flag flag" Chris@155: Chris@156: csvcompare "$tmpcsv" "$mypath/expected/$output-$flag.csv" || \ Chris@156: faildiff "Output differs from expected for output $output and $flag flag" "$tmpcsv" "$mypath/expected/$output-$flag.csv" Chris@156: Chris@158: flag=fill-ends Chris@158: Chris@158: $r -d "$testplug:$output" -w csv --csv-$flag --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@158: fail "Failed to run for plugin $testplug with output $output and $flag flag" Chris@158: Chris@158: csvcompare "$tmpcsv" "$mypath/expected/$output-$flag.csv" || \ Chris@158: faildiff "Output differs from expected for output $output and $flag flag" "$tmpcsv" "$mypath/expected/$output-$flag.csv" Chris@158: Chris@156: flag=end-times Chris@156: Chris@156: $r -d "$testplug:$output" -w csv --csv-$flag --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@156: fail "Failed to run for plugin $testplug with output $output and $flag flag" Chris@156: Chris@156: csvcompare "$tmpcsv" "$mypath/expected/$output-$flag.csv" || \ Chris@156: faildiff "Output differs from expected for output $output and $flag flag" "$tmpcsv" "$mypath/expected/$output-$flag.csv" Chris@156: Chris@156: flag=separator Chris@156: Chris@156: $r -d "$testplug:$output" -w csv --csv-$flag '@' --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@156: fail "Failed to run for plugin $testplug with output $output and $flag flag" Chris@156: Chris@156: csvcompare "$tmpcsv" "$mypath/expected/$output-$flag.csv" || \ Chris@156: faildiff "Output differs from expected for output $output and $flag flag" "$tmpcsv" "$mypath/expected/$output-$flag.csv" Chris@156: Chris@158: flag=all Chris@158: Chris@158: $r -d "$testplug:$output" -w csv --csv-sample-timing --csv-fill-ends --csv-end-times --csv-separator '@' --csv-stdout "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@158: fail "Failed to run for plugin $testplug with output $output and all flags" Chris@158: Chris@158: csvcompare "$tmpcsv" "$mypath/expected/$output-$flag.csv" || \ Chris@158: faildiff "Output differs from expected for output $output and all flags" "$tmpcsv" "$mypath/expected/$output-$flag.csv" Chris@158: Chris@155: done Chris@155: Chris@207: for output in grid-oss; do Chris@207: for digits in 0 6 2; do Chris@207: Chris@207: $r -d "$testplug:$output" -w csv --csv-stdout --csv-digits "$digits" "$infile" 2>/dev/null > "$tmpcsv" || \ Chris@207: fail "Failed to run for plugin $testplug with output $output and digits $digits" Chris@207: Chris@207: # no fuzz here Chris@207: cmp -s "$tmpcsv" "$mypath/expected/$output-$digits.csv" || \ Chris@207: faildiff "Output differs from expected for CSV writer with output $output and digits $digits" "$tmpcsv" "$mypath/expected/$output-$digits.csv" Chris@207: Chris@207: done Chris@207: done Chris@207: Chris@155: exit 0 Chris@155: