1#!/bin/sh -e 2 3pause() 4{ 5 local junk 6 7 printf "Press return to continue..." 8 read junk 9} 10 11cd .. 12./cave-man-install.sh 13cd Test 14../ad2vcf test.vcf 10 < test.sam 15 16cat << EOM 17 18====================================================================== 19Comparing your results to the reference... 20====================================================================== 21 22EOM 23if diff -u test-ad-correct.vcf test-ad.vcf; then 24 printf "No differences found, test passed.\n" 25else 26 printf "Differences found, test failed.\n" 27fi 28mv test-ad.vcf test-ad-last.vcf 29 30cat << EOM 31 32====================================================================== 33The following 4 tests should fail with complaints about input sorting. 34====================================================================== 35 36EOM 37pause 38 39set +e 40printf "=== test-bad-pos.vcf\n" 41../ad2vcf test-bad-pos.vcf 10 < test.sam 42pause 43 44printf "=== test-bad-chr.vcf\n" 45../ad2vcf test-bad-chr.vcf 10 < test.sam 46pause 47 48printf "=== test-bad-pos.sam\n" 49../ad2vcf test.vcf 10 < test-bad-pos.sam 50pause 51 52printf "=== test-bad-chr.sam\n" 53../ad2vcf test.vcf 10 < test-bad-chr.sam 54rm test-ad.vcf 55