[Bioperl-guts-l] [15258] bioperl-live/branches/branch-1-6/t/RemoteDB/HIV/HIVQuery.t: Small fix for tests JIC there is a network error
Christopher John Fields
cjfields at dev.open-bio.org
Wed Dec 24 01:04:09 EST 2008
Revision: 15258
Author: cjfields
Date: 2008-12-24 01:04:09 -0500 (Wed, 24 Dec 2008)
Log Message:
-----------
Small fix for tests JIC there is a network error
Modified Paths:
--------------
bioperl-live/branches/branch-1-6/t/RemoteDB/HIV/HIVQuery.t
Modified: bioperl-live/branches/branch-1-6/t/RemoteDB/HIV/HIVQuery.t
===================================================================
--- bioperl-live/branches/branch-1-6/t/RemoteDB/HIV/HIVQuery.t 2008-12-24 05:27:05 UTC (rev 15257)
+++ bioperl-live/branches/branch-1-6/t/RemoteDB/HIV/HIVQuery.t 2008-12-24 06:04:09 UTC (rev 15258)
@@ -139,14 +139,19 @@
eval {$tobj = Bio::DB::Query::HIVQuery->new(-QUERY=>"(SI[phenotype] ('CCR5 CXCR4')[coreceptor] C[subtype] OR NSI[phenotype] D[subtype]) AND ZA[country]",-RUN_OPTION=>2)};
if ($@) {
diag($@);
- skip("Network problems, skipping all", 10) if $@;
+ skip("Network problems, skipping all", 10);
}
ok($tobj,"live query");
cmp_ok( $tobj->count, ">=", 12, "enough sequences returned");
# test query object handling of Bio::DB::HIV
my ($tdb, $seqio, $seq);
ok( $tdb = new Bio::DB::HIV, "create Bio::DB::HIV object");
- ok($seqio = $tdb->get_Stream_by_query($tobj), "get SeqIO stream from query");
+ eval {$seqio = $tdb->get_Stream_by_query($tobj)};
+ if ($@) {
+ diag($@);
+ skip("Network problems, skipping all", 7);
+ }
+ ok($seqio, "get SeqIO stream from query");
# test HIVAnnotProcessor indirectly
ok($seq = $seqio->next_seq, "access sequence stream");
ok($seq->annotation->get_value('Virus'), "'Virus' annotation present");
More information about the Bioperl-guts-l
mailing list