1 # -*-Perl-*- Test Harness script for Bioperl
10 test_begin(-tests => 16,
11 -requires_modules => [qw(IO::String LWP::UserAgent)]);
13 use_ok('Bio::PrimarySeq');
14 use_ok('Bio::Tools::Analysis::Protein::Sopma');
17 my $verbose = test_debug();
19 ok my $tool = Bio::WebAgent->new(-verbose =>$verbose);
21 my $seq = Bio::PrimarySeq->new(
22 -seq => 'MSADQRWRQDSQDSFGDSFDGDPPPPPPPPFGDSFGDGFSDRSRQDQRS',
23 -display_id => 'test2');
24 ok $tool = Bio::Tools::Analysis::Protein::Sopma->new( -seq=>$seq,
28 test_skip(-tests => 12, -requires_networking => 1);
31 skip "Tool was terminated by some error: problem connecting to server?", 11 if $tool->status eq 'TERMINATED_BY_ERROR';
33 ok my $raw = $tool->result('');
34 ok my $parsed = $tool->result('parsed');
35 is ($parsed->[0]{'helix'}, '104');
36 ok my @res = $tool->result('Bio::SeqFeatureI');
37 ok my $meta = $tool->result('meta', "ww15");
39 ok $tool->window_width(21);
42 ok my $meta2 = $tool->result('meta', "ww21");
45 test_skip(-tests => 2, -requires_module => 'Bio::Seq::Meta::Array');
46 is $meta->named_submeta_text('Sopma_helix|ww15',1,2), '104 195';
47 is $meta->seq, 'MSADQRWRQDSQDSFGDSFDGDPPPPPPPPFGDSFGDGFSDRSRQDQRS';