diff srf2fastq/io_lib-1.12.2/tests/srf_index.test @ 0:d901c9f41a6a default tip

Migrated tool version 1.0.1 from old tool shed archive to new tool shed repository
author dawe
date Tue, 07 Jun 2011 17:48:05 -0400
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/srf2fastq/io_lib-1.12.2/tests/srf_index.test	Tue Jun 07 17:48:05 2011 -0400
@@ -0,0 +1,23 @@
+#!/bin/sh
+# Extract an entry using srf_extract_linear
+chmod u+w $outdir/proc.srf
+$top_builddir/progs/srf_extract_linear $outdir/proc.srf test_run:4:134:369:182 > $outdir/_.srf
+cmp $outdir/_.srf $srcdir/data/test_run_4_134_369_182.srf || exit 1
+
+# Extract using the hash table method - should fail
+echo "NB: The next line is expected to be an error message" 1>&2
+$top_builddir/progs/srf_extract_hash $outdir/proc.srf test_run:4:134:369:182 > $outdir/_.srf
+[ $? = 1 ] || exit 1
+
+# Index it
+$top_builddir/progs/srf_index_hash $outdir/proc.srf
+cmp $outdir/proc.srf $srcdir/data/proc.srf.indexed || exit 1
+
+# Extract using the hash table method
+$top_builddir/progs/srf_extract_hash $outdir/proc.srf test_run:4:134:369:182 > $outdir/_.srf
+[ $? = 0 ] || exit 1
+
+# Check the archive/name access method too
+seq=`$top_builddir/progs/extract_seq $outdir/proc.srf/test_run:4:134:369:182 | tr -d '\012\015'`
+[ "$seq" = "GGTAGAGATTCTCTTGTTGACATTTTAAAAGAGCGTGTCTGGAAACGTACGGATTGTTCAGTAACTTGACTCAT" ] || exit 1
+