Created
May 17, 2010 18:24
-
-
Save cjfields/404061 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# this is mainly GFF3-specific, GFF2/GTF to be added | |
my ($io, $f, $s, $fcount, $scount); | |
################################################################################ | |
# | |
# use FeatureIO::gff to read a FASTA file. | |
# | |
$fcount = 0; | |
$scount = 0; | |
ok( $io = Bio::FeatureIO->new( -file => test_input_file('dna1.fa') ) ); | |
#read features | |
while($f = $io->next_feature()){ | |
warn $f; | |
$fcount++; | |
} | |
is($fcount, 0); | |
#then try to read sequences again. should get seqs now | |
while($s = $io->next_seq()){ | |
$scount++; | |
TODO: { | |
local $TODO = 'How did this ever work?!?'; | |
if ($scount == 1) { | |
is($s->seq, 'Test1'); | |
} | |
} | |
} | |
is($scount, 1); | |
__END__ | |
Result: | |
not ok 4 # TODO How did this ever work?!? | |
# Failed (TODO) test at t/SeqFeature/FeatureIO.t line 43. | |
# got: 'TTCTGAACTGGTTACCTGCCGTGAGTAAATTAAAATTTTATTGACTTAGGTCACTAAATACTTTAACCAATATAGGCATAGCGCACAGACAGATAAAAATTACAGAGTACACAACATCCATGAAACGCATTAGCACCACC' | |
# expected: 'Test1' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment