1 # -*-Perl-*- Test Harness script for Bioperl
10 test_begin(-tests => 13,
11 -requires_modules => [qw(IO::String LWP::UserAgent)],
12 -requires_networking => 1);
15 use_ok("Bio::Tools::Analysis::Protein::HNN");
18 my $seq = Bio::Seq->new(-seq => 'MSADQRWRQDSQDSFGDSFDGDPPPPPPPPFGDSFGDGFSDRSRQDQRS',
19 -display_id => 'test2');
20 ok my $tool = Bio::Tools::Analysis::Protein::HNN->new(-seq=>$seq->primary_seq);
24 skip "Skipping tests since we got terminated by a server error", 9 if $tool->status eq 'TERMINATED_BY_ERROR';
25 ok my $raw = $tool->result('');
26 ok my $parsed = $tool->result('parsed');
27 is $parsed->[0]{'coil'}, '1000';
28 my @res = $tool->result('Bio::SeqFeatureI');
29 if (scalar @res > 0) {
33 skip 'No results - could not connect to HNN server?', 6;
36 ok my $meta = $tool->result('meta');
37 ok my $seqobj = Bio::Seq->new(-primary_seq => $meta, display_id=>"a");
38 ok $seqobj->add_SeqFeature($tool->result('Bio::SeqFeatureI'));
40 test_skip(-tests => 2, -requires_module => 'Bio::Seq::Meta::Array');
41 is $meta->named_submeta_text('HNN_helix',1,2), '0 111';
42 is $meta->seq, 'MSADQRWRQDSQDSFGDSFDGDPPPPPPPPFGDSFGDGFSDRSRQDQRS';