stevedlawrence commented on code in PR #1682:
URL: https://github.com/apache/daffodil/pull/1682#discussion_r3397256316
##########
daffodil-core/src/main/scala/org/apache/daffodil/lib/xml/XMLUtils.scala:
##########
@@ -1302,6 +1302,16 @@ Differences were (path, expected, actual):
}
}
+ /**
+ * Normalizing fractional seconds to milliseconds precision.
+ * @param data Date/Time
+ * @return normalized data with microseconds precision dropped.
+ */
+ private def normalizeFractionalSeconds(data: String): String = {
+ // match ".ffffff" after seconds, keep at most 3 digits
+ data.replaceAll("""(\.\d{3})\d+""", "$1")
Review Comment:
I think it's fine if year zero throws IllegalArgumentException. That is not
valid XSD so Daffodil should never create it (once we fix the referenced
issue). If a TDML file has year 0 as an expected infoset then it's fine for
that test to fail with a TDML exception about an invalid date/time field.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]