X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=t%2Fpsgi_search.t;h=3da93eda718cd7335c2b1f747f2a7f16e2bf880e;hb=d07ba9c30800225052d17ccca458afbfa05a8ff0;hp=d59e439b124777a53e7f9d07d56348a0d096f2e3;hpb=1889f299079a45831d4e147d59d32d5c283798c5;p=public-inbox.git diff --git a/t/psgi_search.t b/t/psgi_search.t index d59e439b..3da93eda 100644 --- a/t/psgi_search.t +++ b/t/psgi_search.t @@ -8,7 +8,6 @@ use IO::Uncompress::Gunzip qw(gunzip); use PublicInbox::Eml; use PublicInbox::Config; use PublicInbox::Inbox; -use bytes (); # only for bytes::length my @mods = qw(DBD::SQLite Search::Xapian HTTP::Request::Common Plack::Test URI::Escape Plack::Builder); require_mods(@mods); @@ -88,6 +87,10 @@ test_psgi(sub { $www->call(@_) }, sub { is($res->code, 200, 'successful search result'); is_deeply([], $warn, 'no warnings from non-numeric comparison'); + $res = $cb->(GET('/test/?&q=s:test')); + is($res->code, 200, 'successful search result'); + is_deeply([], $warn, 'no warnings from black parameter'); + $res = $cb->(POST('/test/?q=s:bogus&x=m')); is($res->code, 404, 'failed search result gives 404'); is_deeply([], $warn, 'no warnings');