]> Sergey Matveev's repositories - public-inbox.git/commitdiff
fix tests to run without Xapian installed
authorEric Wong (Contractor, The Linux Foundation) <e@80x24.org>
Thu, 19 Apr 2018 19:23:32 +0000 (19:23 +0000)
committerEric Wong <e@80x24.org>
Thu, 19 Apr 2018 19:44:18 +0000 (19:44 +0000)
We'll be ensuring we can run more of the HTTP and all of the
NNTP interface with only SQLite (and not Xapian) installed
in the future.

t/over.t
t/v1-add-remove-add.t

index c0d9d5e54e58a475026ffed20a3d71d0ad962d76..7a3c972104d6d15024b8fbc8c5e25465e182e308 100644 (file)
--- a/t/over.t
+++ b/t/over.t
@@ -5,7 +5,8 @@ use warnings;
 use Test::More;
 use File::Temp qw/tempdir/;
 use Compress::Zlib qw(compress);
-foreach my $mod (qw(DBD::SQLite)) {
+# FIXME: allow using Over w/o Xapian
+foreach my $mod (qw(DBD::SQLite Search::Xapian)) {
        eval "require $mod";
        plan skip_all => "$mod missing for over.t" if $@;
 }
index cd6e281105c18ee9dd0b8616ea0ae1303b6ac9af..1e11c71e21e1b7a05d3da43ba097bf7b3eec9018 100644 (file)
@@ -5,13 +5,13 @@ use warnings;
 use Test::More;
 use PublicInbox::MIME;
 use PublicInbox::Import;
-use PublicInbox::SearchIdx;
 use File::Temp qw/tempdir/;
 
 foreach my $mod (qw(DBD::SQLite Search::Xapian)) {
        eval "require $mod";
        plan skip_all => "$mod missing for v1-add-remove-add.t" if $@;
 }
+require PublicInbox::SearchIdx;
 my $mainrepo = tempdir('pi-add-remove-add-XXXXXX', TMPDIR => 1, CLEANUP => 1);
 is(system(qw(git init --bare), $mainrepo), 0);
 my $ibx = {