db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@apache.org>
Subject Re: Encoding for test master files.
Date Thu, 27 Jul 2006 23:20:35 GMT
Myrna van Lunteren wrote:

> On 7/27/06, Daniel John Debrunner <djd@apache.org> wrote:
> 
>> I have a new version of my old ijRunner JUnit test class that runs ij
>> scripts within JUnit and compares the output etc. I'll commit in a short
>> while, though it won't be in use yet, it's still a work in progress.
>>
>> One are I need to address is the encoding of the output, what is the
>> default encoding for the master files? I think looking at DERBY-683 work
>> was done to allow test specific encoding, but I'm just current looking
>> at handling the default.
>>
>> Any ideas?
>> Dan.
>>
>>
>>
>>
> I am getting terribly confused on this as I'm trying to answer, so bear
> with me.
> I think the answer is UTF-8.
> DERBY-244 is relevant in this area and maybe DERBY-658.
> 
> With DERBY-658 we made the tests create output in local encoding. We
> read in the master in UTF-8 but have the test convert this to a local
> encoded copy in the .tmpmstr file, which is the one used in the
> diffing.
> So, I think this means the masters are expected to be UTF-8.
> 
> If there's a difference in a test creators' machine-dependent output
> and UTF-8 output, the harness has a flag to create a .utf8out file
> that's to be the actual master.
> For most tests and the more common systems, assuming we're running
> (and that's forced now in the harness) in US-English locale, the
> output with the system's default encoding (i.e. ISO-5889-1 on Unix,
> Cp1252 on Windwos) is close enough to UTF-8 that we don't need to
> worry.
> 
> I haven't looked at Knut Anders' patch for DERBY-244 in detail yet,
> planned to do it today but other things took longer - but looks like
> it's going to force i18n tests to UTF-8 encoding.
> 
> Does this help? Is there a specific test that causes concern?

Yes, this helps, I'll look at mimicing this.

No specific test, I just want to ensure the encoding (in the simple case
at least) is handled up front.

Thanks,
Dan.


Mime
View raw message