Re: testParsingWithoutUTF8Encoding Error
Hi Fábio,
I think the test itself is probably right.
public void testParsingWithUTF8Encoding() throws Exception {
try {
ADLParser parser = new ADLParser(loadFromClasspath(
"adl-test-entry.unicode_BOM_support.test.adl"), "UTF-8");
parser.parse();
} catch(Throwable t) {
fail("failed to parse BOM with UTF8 encoding..");
}
}
If the test fails, I believe something is going wrong in the ADLParser as the archetype cannot be parsed.
Something in the ADLParser is going wrong in a Mac environment without UTF-8 default encoding.
I unfortunately don't own a Mac, and not sure if Rong does, but maybe you can get the error message to us to see what the parser is expecting?
I also notice that the archetype is in Windows format (i.e. using pair of CR and LF characters to terminate lines, whereas Unix uses an LF character only and Mac uses a CR character only.)
Maybe you can convert it to Unix or Mac format and see if that helps (but be sure to keep the invisible Byte order mark (BOM) at the beginning of the file or test may be ok, but not testing what it should test anymore)
Regards
Sebastian
Fábio Nogueira de Lucena wrote:Hi,
the unit test testParsingWithoutUTF8Encoding fails on my Mac. After trying to make my Mac use UTF-8 by default instead of Mac Roman I gave up. However, i am not sure the test is right. The test should work even with a different default encoding, or not?
Thanks in advance.
Fábio
_______________________________________________ Ref_impl_java mailing list Ref_impl_java@openehr.org http://lists.chime.ucl.ac.uk/mailman/listinfo/ref_impl_java
--
Dr. sc. hum., Dipl.-Inform. Med, FACHI
Dr Sebastian GardeSenior Developer
Ocean Informatics
Skype: gardeseb
_______________________________________________
Ref_impl_java mailing list
Ref_impl_java@openehr.org
http://lists.chime.ucl.ac.uk/mailman/listinfo/ref_impl_java
_______________________________________________ Ref_impl_java mailing list Ref_impl_java@openehr.org http://lists.chime.ucl.ac.uk/mailman/listinfo/ref_impl_java