You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/02/23 23:29:18 UTC
[jira] [Commented] (DRILL-4332) tests in TestFrameworkTest fail in
Java 8
[ https://issues.apache.org/jira/browse/DRILL-4332?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15159781#comment-15159781 ]
ASF GitHub Bot commented on DRILL-4332:
---------------------------------------
GitHub user laurentgo opened a pull request:
https://github.com/apache/drill/pull/389
DRILL-4332: Makes vector comparison order stable in test framework
In the test framework, a vector is a map of <String, Object>. When comparing
actual values with baseline, the comparison is made column by column, but
a HashMap key ordering is not guaranteed, and the ordering actually changed
between Java7 and Java8 in Oracle/OpenJDK.
Replacing HashMap with TreeMap which has a guaranteed ordering by design.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/laurentgo/drill laurent/DRILL-4332
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/drill/pull/389.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #389
----
commit 7de03c933e78751eb5f95fa49513f4d57a72a218
Author: Laurent Goujon <la...@dremio.com>
Date: 2016-02-23T22:14:37Z
DRILL-4332: Makes vector comparison order stable in test framework
In the test framework, a vector is a map of <String, Object>. When comparing
actual values with baseline, the comparison is made column by column, but
a HashMap key ordering is not guaranteed, and the ordering actually changed
between Java7 and Java8 in Oracle/OpenJDK.
Replacing HashMap with TreeMap which has a guaranteed ordering by design.
----
> tests in TestFrameworkTest fail in Java 8
> -----------------------------------------
>
> Key: DRILL-4332
> URL: https://issues.apache.org/jira/browse/DRILL-4332
> Project: Apache Drill
> Issue Type: Sub-task
> Components: Tools, Build & Test
> Affects Versions: 1.5.0
> Reporter: Deneche A. Hakim
> Fix For: Future
>
>
> the following unit tests fail in Java 8:
> {noformat}
> TestFrameworkTest.testRepeatedColumnMatching
> TestFrameworkTest.testCSVVerificationOfOrder_checkFailure
> {noformat}
> The tests expect the query to fail with a specific error message. The message generated by DrillTestWrapper.compareMergedVectors assumes a specific order in a map keySet (which we shouldn't). In Java 8 it seems the order changed which causes a slightly different error message
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)