maint: remove Travis stuff which has been replaced with Github actions (#325)
[bioperl-live.git] / t / SeqIO / kegg.t
blobe1970c6f62fc418ff459b4c401475fd22c5074d5
1 # -*-Perl-*- Test Harness script for Bioperl
2 # $Id$
4 use strict;
6 BEGIN {
7     use Bio::Root::Test;
8     
9     test_begin(-tests => 16);
10         
11         use_ok('Bio::SeqIO::kegg');
14 my $verbose = test_debug();
16 my $io = Bio::SeqIO->new(-format => 'kegg',
17                                                                  -verbose => $verbose,
18                                                                  -file => test_input_file('AHCYL1.kegg'));
19 isa_ok($io, 'Bio::SeqIO');
20 my $kegg = $io->next_seq();
21 ok($kegg);
22 isa_ok($kegg, 'Bio::Seq::RichSeq');
23 is($kegg->accession, '10768');
24 is($kegg->display_id, 'AHCYL1');
25 is($kegg->alphabet, 'dna');
26 is($kegg->seq,'atgtcgatgcctgacgcgatgccgctgcccggggtcggggaggagctgaagcaggccaaggagatcgaggacgccgagaagtactccttcatggccaccgtcaccaaggcgcccaagaagcaaatccagtttgctgatgacatgcaggagttcaccaaattccccaccaaaactggccgaagatctttgtctcgctcgatctcacagtcctccactgacagctacagttcagctgcatcctacacagatagctctgatgatgaggtttctccccgagagaagcagcaaaccaactccaagggcagcagcaatttctgtgtgaagaacatcaagcaggcagaatttggacgccgggagattgagattgcagagcaagacatgtctgctctgatttcactcaggaaacgtgctcagggggagaagcccttggctggtgctaaaatagtgggctgtacacacatcacagcccagacagcggtgttgattgagacactctgtgccctgggggctcagtgccgctggtctgcttgtaacatctactcaactcagaatgaagtagctgcagcactggctgaggctggagttgcagtgttcgcttggaagggcgagtcagaagatgacttctggtggtgtattgaccgctgtgtgaacatggatgggtggcaggccaacatgatcctggatgatgggggagacttaacccactgggtttataagaagtatccaaacgtgtttaagaagatccgaggcattgtggaagagagcgtgactggtgttcacaggctgtatcagctctccaaagctgggaagctctgtgttccggccatgaacgtcaatgattctgttaccaaacagaagtttgataacttgtactgctgccgagaatccattttggatggcctgaagaggaccacagatgtgatgtttggtgggaaacaagtggtggtgtgtggctatggtgaggtaggcaagggctgctgtgctgctctcaaagctcttggagcaattgtctacattaccgaaatcgaccccatctgtgctctgcaggcctgcatggatgggttcagggtggtaaagctaaatgaagtcatccggcaagtcgatgtcgtaataacttgcacaggaaataagaatgtagtgacacgggagcacttggatcgcatgaaaaacagttgtatcgtatgcaatatgggccactccaacacagaaatcgatgtgaccagcctccgcactccggagctgacgtgggagcgagtacgttctcaggtggaccatgtcatctggccagatggcaaacgagttgtcctcctggcagagggtcgtctactcaatttgagctgctccacagttcccacctttgttctgtccatcacagccacaacacaggctttggcactgatagaactctataatgcacccgaggggcgatacaagcaggatgtgtacttgcttcctaagaaaatggatgaatacgttgccagcttgcatctgccatcatttgatgcccaccttacagagctgacagatgaccaagcaaaatatctgggactcaacaaaaatgggccattcaaacctaattattacagatactaa');
27 ok($kegg->translate->seq);
29 is(($kegg->annotation->get_Annotations('description'))[0]->text,
30    'S-adenosylhomocysteine hydrolase-like 1 [EC:3.3.1.1]');
32 is(($kegg->annotation->get_Annotations('pathway'))[0]->text,
33    'Metabolism; Amino Acid Metabolism; Methionine metabolism');
35 is( (grep {$_->database eq 'KO'}
36      $kegg->annotation->get_Annotations('dblink'))[0]->comment, 
37     'adenosylhomocysteinase' );
39 is( (grep {$_->database eq 'PATH'} 
40      $kegg->annotation->get_Annotations('dblink'))[0]->primary_id,
41     'hsa00271' );
43 is( ($kegg->annotation->get_Annotations('aa_seq'))[0]->text,
44 'MSMPDAMPLPGVGEELKQAKEIEDAEKYSFMATVTKAPKKQIQFADDMQEFTKFPTKTGRRSLSRSISQSSTDSYSSAASYTDSSDDEVSPREKQQTNSKGSSNFCVKNIKQAEFGRREIEIAEQDMSALISLRKRAQGEKPLAGAKIVGCTHITAQTAVLIETLCALGAQCRWSACNIYSTQNEVAAALAEAGVAVFAWKGESEDDFWWCIDRCVNMDGWQANMILDDGGDLTHWVYKKYPNVFKKIRGIVEESVTGVHRLYQLSKAGKLCVPAMNVNDSVTKQKFDNLYCCRESILDGLKRTTDVMFGGKQVVVCGYGEVGKGCCAALKALGAIVYITEIDPICALQACMDGFRVVKLNEVIRQVDVVITCTGNKNVVTREHLDRMKNSCIVCNMGHSNTEIDVTSLRTPELTWERVRSQVDHVIWPDGKRVVLLAEGRLLNLSCSTVPTFVLSITATTQALALIELYNAPEGRYKQDVYLLPKKMDEYVASLHLPSFDAHLTELTDDQAKYLGLNKNGPFKPNYYRY');
46 is( ($kegg->annotation->get_Annotations('position'))[0]->text, '1:join(26813..26932,50794..50905,52974..53117,54122..54222,54657..
47             54759,56523..56617,57185..57291,58104..58220,58427..58490,59255..
48             59343,59706..59776,60133..60227,60312..60410,60811..60879,61308..
49             61386,62491..62611,63434..63440)');
51 is($kegg->species->common_name , 'H.sapiens');