X-Git-Url: http://woldlab.caltech.edu/gitweb/?p=tabix.git;a=blobdiff_plain;f=debian%2Ftests%2Fwith-example-data;fp=debian%2Ftests%2Fwith-example-data;h=6af6ecf0b467242ead0f325c479c679374b69755;hp=0000000000000000000000000000000000000000;hb=7677e4520ec9c535985331d2027045611a09523c;hpb=2836b515b23a476c4c6629750971b60158208338 diff --git a/debian/tests/with-example-data b/debian/tests/with-example-data new file mode 100755 index 0000000..6af6ecf --- /dev/null +++ b/debian/tests/with-example-data @@ -0,0 +1,26 @@ +#!/bin/sh -e + +# Create a temporary file +TABIXDATA=$(mktemp) + +# Uncompress example data +zcat /usr/share/doc/tabix/examples/example.gtf.gz > $TABIXDATA + +# Compress example data with bgzip +bgzip $TABIXDATA + +# Index with tabix +tabix $TABIXDATA.gz + +# Extract with tabix the he features on chromosome 1 whose coordinates overlap +# the interval 150,309–150,309. +tabix $TABIXDATA.gz chr1:150309-150309 > $TABIXDATA.out + +# Reference result at the bottom of this file +grep H\AVANA /usr/share/doc/tabix/README.test > $TABIXDATA.ref + +# No difference ? +diff $TABIXDATA.ref $TABIXDATA.out + +# Clean +rm $TABIXDATA.gz $TABIXDATA.gz.tbi $TABIXDATA.out $TABIXDATA.ref