Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Devel-Examine-Subs CPAN distribution.

Report information
The Basics
Id: 107412
Status: resolved
Priority: 0/
Queue: Devel-Examine-Subs

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

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



Subject: t/43-write_failure.t may fail in a non-English locale (1.44_01)
If running the 1.44_01 test suite under a German locale, then the following error happens: # Failed test 'croak if file can't be written to' # at t/43-write_failure.t line 28. # ' # Devel::Examine::Subs::_write_file() speaking... # # File::Edit::Portable::write() returned a failure status. # # can't open file /usr/bin/no_write.data for writing!: Zugriff verweigert at /usr/home/eserte/.cpan/build/2015092918/Devel-Examine-Subs-1.44_01-Hz2ukr/blib/lib/Devel/Examine/Subs.pm line 729. # at t/43-write_failure.t line 25. # ' # doesn't match '(?^i:permission denied)' # Looks like you failed 1 test of 2. t/43-write_failure.t ....................... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests Note that this happens only for perls < 5.22.0 --- probably because errno+locale handling changed in perl 5.22.0. In any way, it would be better if you would check for numeric $! if it's available, or otherwise try to force an English locale early (e.g. by setting LC_ALL=C LANGUAGE=en or so).
On 2015-09-29 14:05:45, SREZIC wrote: Show quoted text
> If running the 1.44_01 test suite under a German locale, then the > following error happens: > > # Failed test 'croak if file can't be written to' > # at t/43-write_failure.t line 28. > # ' > # Devel::Examine::Subs::_write_file() speaking... > # > # File::Edit::Portable::write() returned a failure status. > # > # can't open file /usr/bin/no_write.data for writing!: Zugriff > verweigert at /usr/home/eserte/.cpan/build/2015092918/Devel-Examine- > Subs-1.44_01-Hz2ukr/blib/lib/Devel/Examine/Subs.pm line 729. > # at t/43-write_failure.t line 25. > # ' > # doesn't match '(?^i:permission denied)' > # Looks like you failed 1 test of 2. > t/43-write_failure.t ....................... > Dubious, test returned 1 (wstat 256, 0x100) > Failed 1/2 subtests > > > Note that this happens only for perls < 5.22.0 --- probably because > errno+locale handling changed in perl 5.22.0. In any way, it would be > better if you would check for numeric $! if it's available, or > otherwise try to force an English locale early (e.g. by setting > LC_ALL=C LANGUAGE=en or so).
1.44_02 looks good.
Subject: Re: [rt.cpan.org #107412] t/43-write_failure.t may fail in a non-English locale (1.44_01)
Date: Wed, 30 Sep 2015 08:57:56 -0600
To: bug-Devel-Examine-Subs [...] rt.cpan.org
From: Steve Bertrand <steve.bertrand [...] gmail.com>
Thanks a lot for your feedback, I greatly appreciate it. I should have known that other people use different languages, so testing against system output was a bad idea :) I've changed it to check for output that my application produces (which shouldn't change language). I'll look at using $!. Cheers, Steve On Tue, Sep 29, 2015 at 2:18 PM, Slaven_Rezic via RT < bug-Devel-Examine-Subs@rt.cpan.org> wrote: Show quoted text
> Queue: Devel-Examine-Subs > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=107412 > > > On 2015-09-29 14:05:45, SREZIC wrote:
> > If running the 1.44_01 test suite under a German locale, then the > > following error happens: > > > > # Failed test 'croak if file can't be written to' > > # at t/43-write_failure.t line 28. > > # ' > > # Devel::Examine::Subs::_write_file() speaking... > > # > > # File::Edit::Portable::write() returned a failure status. > > # > > # can't open file /usr/bin/no_write.data for writing!: Zugriff > > verweigert at /usr/home/eserte/.cpan/build/2015092918/Devel-Examine- > > Subs-1.44_01-Hz2ukr/blib/lib/Devel/Examine/Subs.pm line 729. > > # at t/43-write_failure.t line 25. > > # ' > > # doesn't match '(?^i:permission denied)' > > # Looks like you failed 1 test of 2. > > t/43-write_failure.t ....................... > > Dubious, test returned 1 (wstat 256, 0x100) > > Failed 1/2 subtests > > > > > > Note that this happens only for perls < 5.22.0 --- probably because > > errno+locale handling changed in perl 5.22.0. In any way, it would be > > better if you would check for numeric $! if it's available, or > > otherwise try to force an English locale early (e.g. by setting > > LC_ALL=C LANGUAGE=en or so).
> > 1.44_02 looks good. > >