]> Sergey Matveev's repositories - public-inbox.git/blobdiff - t/plack.t
www: omit [thread overview] link for unindexed v1
[public-inbox.git] / t / plack.t
index 20f5d8d5e96b25487859b149ae5bfd4d5ad41f8e..1cee286d63a61e157e53dc88c8ba0e9dec9564e4 100644 (file)
--- a/t/plack.t
+++ b/t/plack.t
@@ -1,5 +1,5 @@
 #!perl -w
-# Copyright (C) 2014-2021 all contributors <meta@public-inbox.org>
+# Copyright (C) all contributors <meta@public-inbox.org>
 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
 use strict;
 use v5.10.1;
@@ -154,9 +154,12 @@ my $c1 = sub {
        $res = $cb->(GET($pfx . $path));
        is(200, $res->code, "success for $path");
        my $html = $res->content;
+       like($html, qr!\bhref="\Q../_/text/help/"!, 'help available');
        like($html, qr!<title>hihi - Me</title>!, 'HTML returned');
-       like($html, qr!<a\nhref="raw"!s, 'raw link present');
+       like($html, qr!<a\nhref=raw!s, 'raw link present');
        like($html, qr!&gt; quoted text!s, 'quoted text inline');
+       unlike($html, qr!thread overview!,
+               'thread overview not shown w/o ->over');
 
        $path .= 'f/';
        $res = $cb->(GET($pfx . $path));