1 # -*-Perl-*- Test Harness script for Bioperl
10 test_begin(-tests => 15,
11 -requires_module => 'IO::String');
14 use_ok('Bio::SearchIO');
15 use_ok('Bio::Index::Blast');
18 END { unlink qw( Wibbl Wibbl.pag Wibbl.dir ); }
20 my $index = Bio::Index::Blast->new(-filename => 'Wibbl',
24 $index->make_index(test_input_file('multi_blast.bls'));
25 ($index->dbm_package eq 'SDBM_File') ?
26 (ok(-e "Wibbl.pag" && -e "Wibbl.dir")) :
29 foreach my $id ( qw(CATH_RAT PAPA_CARPA) ) {
30 my $fh = $index->get_stream($id);
33 my $report = Bio::SearchIO->new(-noclose => 1,
36 my $result = $report->next_result;
37 like($result->query_name, qr/$id/);
38 ok( $result->next_hit);
40 like( $index->fetch_report($id)->query_name, qr/$id/);