projects
/
irspy-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
ac0ba2c
)
More robustness against $rs->record() failure.
author
Mike Taylor
<mike@indexdata.com>
Thu, 8 Mar 2007 14:51:01 +0000
(14:51 +0000)
committer
Mike Taylor
<mike@indexdata.com>
Thu, 8 Mar 2007 14:51:01 +0000
(14:51 +0000)
lib/ZOOM/IRSpy/Test/ResultSet/Named.pm
patch
|
blob
|
history
diff --git
a/lib/ZOOM/IRSpy/Test/ResultSet/Named.pm
b/lib/ZOOM/IRSpy/Test/ResultSet/Named.pm
index
8bc7625
..
61596ae
100644
(file)
--- a/
lib/ZOOM/IRSpy/Test/ResultSet/Named.pm
+++ b/
lib/ZOOM/IRSpy/Test/ResultSet/Named.pm
@@
-1,4
+1,4
@@
-# $Id: Named.pm,v 1.3 2007-03-05 12:53:57 mike Exp $
+# $Id: Named.pm,v 1.4 2007-03-08 14:51:01 mike Exp $
# See the "Main" test package for documentation
# See the "Main" test package for documentation
@@
-65,7
+65,12
@@
sub completed_search_b {
if ($test_args->{'hits_a'} > 0) {
my $hits = $rs->size();
if ($test_args->{'hits_a'} > 0) {
my $hits = $rs->size();
- my $record = $rs->record(0)->raw();
+ my $rsrec = $rs->record(0);
+ if (!defined $rsrec) {
+ eval { $conn->check() };
+ return error($conn, $task, $test_args, $@);
+ }
+ my $record = $rsrec->raw();
if ($hits != $test_args->{'hits_a'}) {
$conn->log('irspy_test', 'Named result set not supported: ',
if ($hits != $test_args->{'hits_a'}) {
$conn->log('irspy_test', 'Named result set not supported: ',