Skip Menu |

This queue is for tickets about the IO-Async CPAN distribution.

Report information
The Basics
Id: 131029
Status: resolved
Priority: 0/
Queue: IO-Async

People
Owner: Nobody in particular
Requestors: richard [...] matrix.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 0.75



Subject: tests fail cryptically if /etc/protocols is absent
Date: Tue, 19 Nov 2019 13:12:58 +0000
To: bug-IO-Async [...] rt.cpan.org
From: Richard van der Hoff <richard [...] matrix.org>
I now (after some time investigating) know that the following test failure is due to getprotobyname("tcp") failing (with 'No such file or directory') if /etc/protocols is absent... but it would have saved a bunch of time if the test result was slightly less cryptic: ----- docker run --rm debian:buster bash -c "apt-get update && apt-get -y install --no-install-recommends build-essential perl zlib1g-dev && cpan i IO::Async" ... much spew follows ... t/42function.t ............... ok Test died early at t/50resolver.t line 104. # Tests were run but no plan was declared and done_testing() was not seen. # Looks like your test exited with -1 just after 6. t/50resolver.t ............... Dubious, test returned 255 (wstat 65280, 0xff00) All 6 subtests passed t/51loop-connect.t ........... ok t/52loop-listen.t ............ ok t/53loop-extend.t ............ ok t/60protocol.t ............... ok t/61protocol-stream.t ........ ok t/62protocol-linestream.t .... ok t/63handle-connect.t ......... ok t/64handle-bind.t ............ ok t/70future-io.t .............. skipped: Future::IO is not available t/99pod.t .................... skipped: Test::Pod 1.00 required for testing POD Test Summary Report ------------------- t/50resolver.t (Wstat: 65280 Tests: 6 Failed: 0) Non-zero exit status: 255 Parse errors: No plan found in TAP output Files=62, Tests=1578, 103 wallclock secs ( 0.30 usr 0.09 sys + 7.17 cusr 1.26 csys = 8.82 CPU) Result: FAIL Failed 1/62 test programs. 0/1578 subtests failed. PEVANS/IO-Async-0.74.tar.gz ./Build test -- NOT OK
Ahyes. Probably best just to skip that test entirely if the synchronous query version didn't yield a result. In any case some platforms are lacking that file (e.g. Android) and otherwise seem to work OK anyway. -- Paul Evans
Subject: rt131029.patch
=== modified file 't/50resolver.t' --- t/50resolver.t 2018-02-21 12:38:45 +0000 +++ t/50resolver.t 2019-11-22 23:21:54 +0000 @@ -94,7 +94,8 @@ my @proto = getprotobyname( "tcp" ); -{ +SKIP: { + skip "getprotobyname - No protocol", 1 unless @proto; my $result; $resolver->resolve(