From f6f0cfb7f3b673f05a95e8c9c3bc7d31580feadc Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 19 Dec 2019 05:18:01 +0000 Subject: view: show percentage in search results thread skeleton The displays the Xapian ->get_percent value in the skeleton to improve scanning of relevancy; irrelevant results do not display that. This fixes broken #anchor links introduced in the previous commit, irrelevant messages now link to the /$INBOX/$MESSAGE_ID page. --- t/psgi_v2.t | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 't') diff --git a/t/psgi_v2.t b/t/psgi_v2.t index 8e81e89b..10176516 100644 --- a/t/psgi_v2.t +++ b/t/psgi_v2.t @@ -155,7 +155,7 @@ test_psgi(sub { $www->call(@_) }, sub { is($res->code, 200, 'success with threaded search'); my $raw = $res->content; ok($raw =~ s/\A.*>Results 1-3 of 3\b//s, 'got all results'); - my @over = ($raw =~ m/\d{4}-\d+-\d+\s+\d+:\d+ (.+)$/gm); + my @over = ($raw =~ m/\d{4}-\d+-\d+\s+\d+:\d+ +(?:\d+\% )?(.+)$/gm); is_deeply(\@over, [ '