Bug in openEHR RM Core

Hi,

I found a bug at org.openehr.rm.datatypes.quantity.datetime.DvDateTimeParser.convertTimeZone(int tzMillis, boolean isExtended), when you invoke with tzMillis = -10800000 (GMT-0300). The correct answer should be “-0300”, not “–0300”.

Here is the suggested correction (patch)

Very good, Humberto!

I just found out setting default locale to pt-BR can’t reproduce the error and it’s to do with default timezone. The newly added testcase DvDateTimeParserTimeZoneTest can force the error regardless what timezone you are in if run alone. It doesn’t do so when run with other tests. Some suggests that default TimeZone is cached by threads.

Cheers,
Rong