Skip Menu |
 

This queue is for tickets about the Win32-OLE CPAN distribution.

Report information
The Basics
Id: 53704
Status: open
Priority: 0/
Queue: Win32-OLE

People
Owner: JDB [...] cpan.org
Requestors: kmx [...] cpan.org
Cc:
AdminCc:

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



Subject: t/ole.t failing test 42 (translate ANSI->OEM)
Hi,

I have experienced failing test "# 42. Translate character from ANSI -> OEM" in t/ole.t - here is the failing message:

Show quoted text
# Excel version is 11.0
# ANSI(cp1252) -> OEM(cp437/cp850): 163 -> 156
# ANSI is "ú" (163) and OEM is "Ł" (157)
not ok 42

I am pretty sure that the reason is Eastern Europe locale on my Windows box = ANSI:cp1250 OEM:cp852

The same behaviour on Win32 strawberry perl 5.8.9 and 5.10.1.

Would it be possible to somehow modify this test to be ready for non English/Latin1 Windows? Even skipping the test on non-English Windows would be fine.

Thanks.

--
kmx


Subject: RE: [rt.cpan.org #53704] t/ole.t failing test 42 (translate ANSI->OEM)
Date: Thu, 14 Jan 2010 16:50:31 -0800
To: <bug-Win32-OLE [...] rt.cpan.org>, "'undisclosed-recipients:'"
From: "Jan Dubois" <jand [...] activestate.com>
Download (untitled) / with headers
text/plain 1017b
On Thu, 14 Jan 2010, kmx via RT wrote: Show quoted text
> > I have experienced failing test "# 42. Translate character from ANSI -> OEM" in > t/ole.t - here is the failing message: > > # Excel version is 11.0 > # ANSI(cp1252) -> OEM(cp437/cp850): 163 -> 156 > # ANSI is "ú" (163) and OEM is "Ł" (157) > not ok 42 > > I am pretty sure that the reason is Eastern Europe locale on my Windows box = > ANSI:cp1250 OEM:cp852
Yes, that diagnosis is correct. The test assumes that the OEM codepage is either 437 or 850 and might fail for any other code page that doesn't map the Pound sign to chr(156). Show quoted text
> The same behaviour on Win32 strawberry perl 5.8.9 and 5.10.1. > > Would it be possible to somehow modify this test to be ready for non > English/Latin1 Windows? Even skipping the test on non-English Windows would be > fine.
Can you confirm that the following command prints "852" on your system? perl -MWin32::OLE::NLS -we"print GetLocaleInfo(GetSystemDefaultLCID(), Win32::OLE::NLS::LOCALE_IDEFAULTCODEPAGE)" Cheers, -Jan
Show quoted text
> Can you confirm that the following command prints "852" on your
> system?
>
> perl -MWin32::OLE::NLS -we"print GetLocaleInfo(GetSystemDefaultLCID(),
> Win32::OLE::NLS::LOCALE_IDEFAULTCODEPAGE)"

Yes, exactly as you have expected.

--
kmx



This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.