From: Eric Wong Date: Fri, 15 Nov 2024 02:59:27 +0000 (+0000) Subject: tests: fix missing modules under TEST_RUN_MODE=0 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9fcbea000d36be144b6c026d5bac81608d2abb8e;p=thirdparty%2Fpublic-inbox.git tests: fix missing modules under TEST_RUN_MODE=0 By default, we rely heavily on preload to speed up tests and missing modules were always present by the time we hit some tests. However, the more realistic (and significantly slower) TEST_RUN_MODE=0 doesn't preload so we must explicitly load missing modules. --- diff --git a/t/extsearch.t b/t/extsearch.t index 28c43763c..1a212bc8d 100644 --- a/t/extsearch.t +++ b/t/extsearch.t @@ -609,6 +609,7 @@ if ('indexheader support') { $es = PublicInbox::Config->new($cfg_path)->ALL; my $mset = $es->mset('xarchiveshash:deadbeefcafe'); is $mset->size, 1, 'extindex.*.indexheader works'; + require PublicInbox::XapClient; local $PublicInbox::Search::XHC = PublicInbox::XapClient::start_helper('-j0') or xbail "no XHC: $@"; diff --git a/t/www_static.t b/t/www_static.t index 8fb86a82e..e258be1cf 100644 --- a/t/www_static.t +++ b/t/www_static.t @@ -16,6 +16,7 @@ my $psgi_env = sub { # @_ is passed to WwwStatic->new write_file '>', $ret, <new(docroot => "$tmpdir" @_); builder { sub { \$ws->call(shift) } } EOM