rdblue commented on a change in pull request #1579:
URL: https://github.com/apache/iceberg/pull/1579#discussion_r503394765



##########
File path: 
mr/src/test/java/org/apache/iceberg/mr/hive/TestHiveIcebergFilterFactory.java
##########
@@ -207,8 +206,8 @@ public void testBooleanType() {
   @Test
   public void testDateType() {
     SearchArgument.Builder builder = SearchArgumentFactory.newBuilder();
-    Date gmtDate = new Date(LocalDate.of(2015, 11, 
12).atStartOfDay(ZoneOffset.UTC).toInstant().toEpochMilli());
-    SearchArgument arg = builder.startAnd().equals("date", 
PredicateLeaf.Type.DATE, gmtDate).end().build();
+    Date date = Date.valueOf("2015-11-12");

Review comment:
       We need to avoid using classes that will change behavior based on time 
zone to parse the value of a date or timestamp. This method was purposely not 
used. The problem here is probably that although the instant value is correct, 
the Date uses the JVM time zone somehow.




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to