about summary refs log tree commit homepage
path: root/t/nntpd.t
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-05-14 01:24:08 +0000
committerEric Wong <e@80x24.org>2016-05-14 01:24:08 +0000
commit90e12e68de364f175d79508c96921891cb766ac7 (patch)
tree20210a207581ea0799e5ff13f80072eef6ecf5eb /t/nntpd.t
parent47f28a70bf3c56f441ca5315fdd5c2e84f4d5c57 (diff)
downloadpublic-inbox-90e12e68de364f175d79508c96921891cb766ac7.tar.gz
The Xapian search index is required for the NNTP server, so
there's no point in calling system() for it like we do in
other tests.  This should speed up the test a small amount.
Diffstat (limited to 't/nntpd.t')
-rw-r--r--t/nntpd.t4
1 files changed, 2 insertions, 2 deletions
diff --git a/t/nntpd.t b/t/nntpd.t
index a389a3e9..a9df36dc 100644
--- a/t/nntpd.t
+++ b/t/nntpd.t
@@ -27,7 +27,6 @@ my $addr = $group . '@example.com';
 my $cfgpfx = "publicinbox.$group";
 my $nntpd = 'blib/script/public-inbox-nntpd';
 my $init = 'blib/script/public-inbox-init';
-my $index = 'blib/script/public-inbox-index';
 use_ok 'PublicInbox::Import';
 use_ok 'PublicInbox::Git';
 
@@ -65,7 +64,8 @@ EOF
                 my $im = PublicInbox::Import->new($git, 'test', $addr);
                 $im->add($mime);
                 $im->done;
-                is(0, system($index, $maindir), 'indexed git dir');
+                my $s = PublicInbox::SearchIdx->new($maindir, 1);
+                $s->index_sync;
         }
 
         ok($sock, 'sock created');