X-Git-Url: http://lists.indexdata.dk/cgi-bin?a=blobdiff_plain;f=lib%2FZOOM%2FIRSpy%2FTest%2FRecord%2FFetch.pm;h=c8a8fbd04ee33cdb951b95d95d16703dfc3ca4d4;hb=86cdaa355076964c027297e6e1137c8e74685cdf;hp=5e62a969523073a43a4262f3875fc2ebd58e1c87;hpb=403ced66f3b48705e1e58c3e8caa6336c4008637;p=irspy-moved-to-github.git diff --git a/lib/ZOOM/IRSpy/Test/Record/Fetch.pm b/lib/ZOOM/IRSpy/Test/Record/Fetch.pm index 5e62a96..c8a8fbd 100644 --- a/lib/ZOOM/IRSpy/Test/Record/Fetch.pm +++ b/lib/ZOOM/IRSpy/Test/Record/Fetch.pm @@ -17,6 +17,7 @@ my @queries = ( "\@attr 1=4 computer", "\@attr 1=44 mineral", # Smithsonian doesn't support AP 4! "\@attr 1=1016 water", # Connector Framework only does 1016 + "\@attr 1=1016 \@attr 2=103 x", # Find all records ### We can add more queries here ); @@ -121,13 +122,18 @@ sub record { defined $record ? $record->exception() : $conn->exception()); } else { - $ok = 1; - my $text = $record->render(); - $conn->log("irspy_test", "Successfully retrieved a $syn record"); - if (0) { - print STDERR "Hits: ", $rs->size(), "\n"; - print STDERR "Syntax: ", $syn, "\n"; - print STDERR $text; + my $actual = $record->get("syntax"); + if (lc($actual) ne lc($syn)) { + $conn->log("irspy_test", "requested $syn record, but got $actual"); + } else { + $ok = 1; + my $text = $record->render(); + $conn->log("irspy_test", "Successfully retrieved a $syn record ($actual)"); + if (0) { + print STDERR "Hits: ", $rs->size(), "\n"; + print STDERR "Syntax: ", $syn, "\n"; + print STDERR $text; + } } }