[ 
http://issues.apache.org/jira/browse/DERBY-834?page=comments#action_12367263 ] 

Myrna van Lunteren commented on DERBY-834:
------------------------------------------

This behavior is to be expected when the test is run on a machine that does not 
have the en_US locale set. 

observe this in the .sql: 
----------------------- 
create procedure checkDatabaseLoc(in locale char(12)) parameter style java 
language java external name 
'org.apache.derbyTesting.functionTests.tests.i18n.DefaultLocale.checkDatabaseLocale';
 
create procedure checkRDefaultLoc() parameter style java language java external 
name 
'org.apache.derbyTesting.functionTests.tests.i18n.DefaultLocale.checkRDefaultLocale';
 
-- this current database was created with the default locale 
call checkDatabaseLoc('en_US'); 
call checkRDefaultLoc(); 
------------------------ 
so, it assumes that the default locale was en_US. 

Observe also for example this in the DefaultLocale.java: 
------------------------ 
// used in urlLocale test 
public static void checkRDefaultLocale() throws SQLException 
{ 
System.out.println(savedLocale); 
if (!savedLocale.equals("en_US")) 
throw new SQLException("wrong_locale"); 
} 
-------------------------- 

Now, whether this is a reasonable assumption is a different question... 

So far, the only way I have found of ensuring that the test runs with default 
locale set to en_US is by hacking into the test harness' jvm.java and forcing 
user.country to US and user.language to en. 

Is that an acceptable thing to do? 

I will experiment some more with different ways of setting this parameter. 

Myrna 


> i18n/urlLocale.sql test fails on Windows XP
> -------------------------------------------
>
>          Key: DERBY-834
>          URL: http://issues.apache.org/jira/browse/DERBY-834
>      Project: Derby
>         Type: Bug
>   Components: Test
>  Environment: CYGWIN
> NT-5.2
> i686-unknown
> Sun JDK 1.5 VM
>     Reporter: David Van Couvering

>
> See 
> http://www.multinet.no/~solberg/public/Apache/Derby/testlog/CYGWIN_NT-5.2_i686-unknown/370210-i18nTest_diff.txt
> This failure has been around since forever, I went all the way back to 
> revision 295051 in October 2005 and it was there.
> I don't see this test on my platform (XP, JDK 1.4, en_US locale), maybe it's 
> a Norwegian thing :)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to