You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by GitBox <gi...@apache.org> on 2021/04/07 02:12:32 UTC
[GitHub] [daffodil] jadams-tresys commented on a change in pull request #521: Enabled calendar tests that now work
jadams-tresys commented on a change in pull request #521:
URL: https://github.com/apache/daffodil/pull/521#discussion_r608292726
##########
File path: daffodil-test/src/test/resources/org/apache/daffodil/section05/simple_types/SimpleTypes.tdml
##########
@@ -5935,12 +5935,13 @@
-->
<tdml:parserTestCase name="dateCalendarDaysInFirstWeek5" root="date20"
- model="dateTimeSchema" description="Section 13 Simple Types - calendarDaysInFirstWeek - DFDL-13-143R">
+ model="dateTimeSchema" description="Section 13 Simple Types - calendarDaysInFirstWeek - DFDL-13-143R"
+ roundTrip="twoPass">
Review comment:
So what I believe is actually happening is that on parse "1 03 2013" with dfdl:calendarPattern="W MM yyyy" gets converted to 2013-02-24, but when we go to unparse that, ICU converts it to "5 02 2013" (read as last week of February), which is functionally equivalent to "1 03 2013" (read as first week of March). Note that in 2013 the last week of February also contains the first 2 days of March.
So really I believe the data is just getting normalized to a different value than the original input. Both values are valid. Another option instead of making this a twoPass test is to just change the input data to "5 02 2013".
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org