Skip Menu |

This queue is for tickets about the Net-Frame-Layer-NTP CPAN distribution.

Report information
The Basics
Id: 111228
Status: resolved
Worked: 5 min
Priority: 0/
Queue: Net-Frame-Layer-NTP

People
Owner: VINSWORLD [...] cpan.org
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.00
Fixed in: 1.01



Subject: t/05-ntpsubs.t fails with -Duselongdouble
Test failure seen on a debian system with perl 5.20.1 compiled with -Duselongdouble: # Failed test 1 in t/05-ntpsubs.t at line 7 # t/05-ntpsubs.t line 7 is: ok($ret eq "Jan 14 2016 20:18:32.222784760175273 UTC"); t/05-ntpsubs.t ....... Failed 1/2 subtests There are more fail reports on CPAN Testers: http://matrix.cpantesters.org/?dist=Net-Frame-Layer-NTP%201.00;os=linux;reports=1 Currently all FAILs are for systems with archname =~ /-ld/ (which also means long double).
On 2016-01-16 03:40:06, SREZIC wrote: Show quoted text
> Test failure seen on a debian system with perl 5.20.1 compiled with > -Duselongdouble: > > # Failed test 1 in t/05-ntpsubs.t at line 7 > # t/05-ntpsubs.t line 7 is: ok($ret eq "Jan 14 2016 > 20:18:32.222784760175273 UTC"); > t/05-ntpsubs.t ....... > Failed 1/2 subtests > > There are more fail reports on CPAN Testers: > http://matrix.cpantesters.org/?dist=Net-Frame-Layer- > NTP%201.00;os=linux;reports=1 > Currently all FAILs are for systems with archname =~ /-ld/ (which also > means long double).
Rewriting the test to use Test::More and is() instead of ok() shows the got value (this is on a freebsd 10.1 system, perl also compiled with -Duselongdouble): t/05-ntpsubs.t ....... 1/2 # Failed test at t/05-ntpsubs.t line 7. # got: 'Jan 14 2016 20:18:32.222784760175272822 UTC' # expected: 'Jan 14 2016 20:18:32.222784760175273 UTC' # Looks like you failed 1 test of 2. t/05-ntpsubs.t ....... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests
Floating point calculation will have arbitrary precision length on different architectures, so just take a substr() of the result.