[
https://issues.apache.org/jira/browse/DRILL-5717?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16243616#comment-16243616
]
ASF GitHub Bot commented on DRILL-5717:
---------------------------------------
Github user vvysotskyi commented on a diff in the pull request:
https://github.com/apache/drill/pull/904#discussion_r149613241
--- Diff: exec/java-exec/src/test/java/org/apache/drill/exec/ExecTest.java
---
@@ -120,4 +124,27 @@ protected LogicalExpression parseExpr(String expr)
throws RecognitionException {
return ret.e;
}
+ /**
+ * mock current locale to US
+ */
+ public static void mockUSLocale() {
+ new MockUp<DateTimeUtils>() {
+ @Mock
+ public DateFormatSymbols getDateFormatSymbols(Locale locale) {
+ return new DateFormatSymbols(Locale.US);
+ }
+ };
+ }
+
+ /**
+ * mock current timezone to UTC
+ */
+ public static void mockUTCTimezone() {
--- End diff --
Please rename this method to mockUtcDateTimeZone
> change some date time unit cases with specific timezone or Local
> ----------------------------------------------------------------
>
> Key: DRILL-5717
> URL: https://issues.apache.org/jira/browse/DRILL-5717
> Project: Apache Drill
> Issue Type: Bug
> Components: Tools, Build & Test
> Affects Versions: 1.9.0, 1.11.0
> Reporter: weijie.tong
>
> Some date time test cases like JodaDateValidatorTest is not Local
> independent .This will cause other Local's users's test phase to fail. We
> should let these test cases to be Local env independent.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)