1 # -*-Perl-*- Test Harness script for Bioperl
10 test_begin(-tests => 28);
12 use_ok('Bio::Tools::RepeatMasker');
15 my $inputfilename = test_input_file('repeatmasker.fa.out');
16 my $parser = Bio::Tools::RepeatMasker->new(-file => $inputfilename);
19 my $rpt = $parser->next_result;
20 is ($rpt->feature1->seq_id, "contig11600");
21 is ($rpt->feature1->start, 1337);
22 is ($rpt->feature1->end, 1407);
23 is ($rpt->feature1->strand, 1);
24 is ($rpt->feature1->primary_tag, "Simple_repeat");
25 is ($rpt->feature1->source_tag, "RepeatMasker");
26 is (scalar $rpt->feature1->get_tag_values('Target'), 3);
27 is ($rpt->feature2->seq_id, "(TTAGGG)n");
28 is ($rpt->feature2->start, 2);
29 is ($rpt->feature2->end, 76);
30 is ($rpt->feature1->primary_tag, "Simple_repeat");
31 is ($rpt->feature1->source_tag, "RepeatMasker");
32 is (scalar $rpt->feature2->get_tag_values('Target'), 3);
35 $parser->next_result for 1,2,3;
38 my $rpt = $parser->next_result;
39 is ($rpt->feature1->seq_id, "SL2.30ch10");
40 is ($rpt->feature1->start, 38849);
41 is ($rpt->feature1->end, 38940);
42 is ($rpt->feature1->strand, -1);
43 is ($rpt->feature1->primary_tag, "LTR");
44 is ($rpt->feature1->source_tag, "RepeatMasker");
45 is_deeply ( [ $rpt->feature1->get_tag_values('Target') ], ['LTR_PGSC0003DMS000000301_448',10681,10775] );
46 is ($rpt->feature2->seq_id, "LTR_PGSC0003DMS000000301_448");
47 is ($rpt->feature2->start, 10681);
48 is ($rpt->feature2->end, 10775);
49 is ($rpt->feature2->strand, -1);
50 is ($rpt->feature1->primary_tag, "LTR");
51 is ($rpt->feature1->source_tag, "RepeatMasker");
52 is_deeply ([$rpt->feature2->get_tag_values('Target')],['SL2.30ch10',38849,38940]);