--- trunk/t/swish.t 2004/12/05 14:35:54 13 +++ trunk/t/swish.t 2004/12/05 15:35:53 14 @@ -2,7 +2,7 @@ use strict; -use Test::More tests => 27; +use Test::More tests => 29; use Test::Exception; use lib '.'; use blib; @@ -27,9 +27,11 @@ ok(-e $index, "index exist"); +ok($i->{'cwd'}, "cwd ".$i->{'cwd'}); + ok($i->check_bin, "swish++ check"); -diag $i->{'version'} || die; +ok($i->{'version'}, "version ".$i->{'version'}); ok($i->index_document( 42 => 'meaning of life' ), "index 42"); @@ -50,6 +52,9 @@ cmp_ok($i->{'index_dir'}, 'eq', $index, "index_dir ok"); +# I would rather test search to close it itself! +#$i->finish_update; + foreach my $word (qw(meaning of life)) { my @r = $i->search($word); cmp_ok(scalar @r, '==', 1, "find $word");