[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Running tests with a non-US locale

From: Peter Lundblad <plundblad_at_google.com>
Date: 2007-04-03 19:02:35 CEST

Malcolm Rowe writes:
> For some reason, gettext() on my Linux machine has decided that it would
> like to translate some of Subversion's output to UK English.
> Specifically, 'Authorization failed' now has the UK variant spelling
> 'Authorisation failed'.
>
Ha, so even English-speaking people get hit by this. That's wonderful!
:-) In general, I'm not surprised by this, because libc for example might
have different translations, but isn't this message coming from our own
library?

> Much as I appreciate this behaviour, it's breaking at least the authz
> tests. Contrary to what sussman just suggested in IRC, there _are_
> other locales besides US, so I assume other people already encounter this
> - what do you do to solve it? And more interestingly, is there some way
> we can fix this in the test scripts themselves?
>
> The only fix I've found is to run the tests with e.g.
> LANGUAGE=en_US.UTF-8 - is that suitable to include into the test
> framework somewhere? Alternatively, 'LANGUAGE= LANG=en_US.UTF-8 ...'
> works as well, of course. Either way, don't know whether we can rely on
> UTF-8 support...
>
LANG=C is what I've been using. The "C" locale is guaranteed to exist.
I've just typed LANG=C on the make check command line because I've never
been able to figure out the exact interaction between LC_*, LANG
and LANGUAGE and how to deal with this portably, but that's probalby
just a matter of experimentation. Remember that you need to make sure
svnserve starts in the "C" locale as well when testing that
protocol.

Welcome to the world of i18n;)
Thanks,
//Peter

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Apr 3 19:02:56 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.