develooper Front page | perl.perl5.porters | Postings from February 2003

Re: Odd Locale warnings with bleadperl

Thread Previous
Abe Timmerman
February 23, 2003 08:11
Re: Odd Locale warnings with bleadperl
Message ID:
Op een zonnige winterdag (Sunday 23 February 2003 15:50), schreef Rafael 

> Abe Timmerman wrote:
> > In order to provide a uniform environment for the testsuite during smoke,
> > $ENV{LC_ALL} is localised for the "make test" phase in "", so it
> > is empty (I hadn't realised that):
> >
> > 	~$ perl -wle 'local $ENV{LC_ALL}; print qx/set | grep LC_ALL/'
> > 	LC_ALL=
> >
> > Perhaps I need to change the implementation for that and set its
> > localised value to "C"?
> >
> > Any thoughts?
> Are you referring to this line :
>     local( $ENV{PERLIO}, $ENV{LC_ALL}, $ENV{PERL_UTF8_LOCALE} );
> (in

Yup that is the line.

> I think it's better to initialize them at their previous values.
> This allow to set LC_ALL (for example) to some weird locale (Bulgarian
> for example -- grep Changes5.8 for "Bulgarian" if you don't get it)
> before running the smoke.

I agree for non UTF-8 locales, for which I believe most of the testsuite was 
written. I've created the extra test-run for running under a UTF-8 locale to 
catch the specific UTF-8 errors as was suggested here on p5p.

>                           (apparently the --locale option is for
> another purpose)

That is meant to do the extra test-run for UTF-8 locales only (but only 
F<> actually checks you specify such a locale), so you could 
mis-use it for any locale.

I would like an answer to this issue, so I can release the Test::Smoke-1.16_20 

I can also add a new switch '--force-c-locale' to F<> so the smoker 
can choose (default will be to copy the original setting of $ENV{LC_ALL}). 
Any thoughts on that?

Good luck,

(*) Before the testing posse is on my case :-) let me preempt them by
saying that fake networks don't really help here.  You'll be testing
a fake network.  That proves that the module worked on a fake network.
That's great.  Like drinking decaffeinated.
                                   -- Jarkko Hietaniemi on p5p @ 2001-11-22

Thread Previous Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About