* [PATCH] t/gzip_filter: enhance diagnostics on missing SIGPIPE
@ 2023-04-28 1:08 7% Eric Wong
0 siblings, 0 replies; 1+ results
From: Eric Wong @ 2023-04-28 1:08 UTC (permalink / raw)
To: meta
I encountered this SIGPIPE test not working as intended on
FreeBSD 12.4 once (out of hundreds of runs); but can't reproduce
it...
---
t/gzip_filter.t | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/t/gzip_filter.t b/t/gzip_filter.t
index b349ae58..97eac2d0 100644
--- a/t/gzip_filter.t
+++ b/t/gzip_filter.t
@@ -1,7 +1,7 @@
-# Copyright (C) 2020-2021 all contributors <meta@public-inbox.org>
+#!perl -w
+# Copyright (C) all contributors <meta@public-inbox.org>
# License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
-use strict;
-use Test::More;
+use v5.12;
use IO::Handle (); # autoflush
use Fcntl qw(SEEK_SET);
use PublicInbox::TestCommon;
@@ -31,7 +31,7 @@ require_ok 'PublicInbox::GzipFilter';
open my $fh, '<', 'COPYING' or die "open(COPYING): $!";
my $buf = do { local $/; <$fh> };
while ($filter->write($buf .= rand)) {}
- ok($sigpipe, 'got SIGPIPE');
+ ok($sigpipe, 'got SIGPIPE') or diag "\$!=$!";
close $w;
}
done_testing;
^ permalink raw reply related [relevance 7%]
Results 1-1 of 1 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2023-04-28 1:08 7% [PATCH] t/gzip_filter: enhance diagnostics on missing SIGPIPE Eric Wong
Code repositories for project(s) associated with this public inbox
https://80x24.org/public-inbox.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).