You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Hadoop QA (JIRA)" <ji...@apache.org> on 2014/03/23 21:59:42 UTC

[jira] [Commented] (ZOOKEEPER-1901) [JDK8] Sort children for comparison in AsyncOps tests

    [ https://issues.apache.org/jira/browse/ZOOKEEPER-1901?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13944570#comment-13944570 ] 

Hadoop QA commented on ZOOKEEPER-1901:
--------------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12636261/ZOOKEEPER-1901.patch
  against trunk revision 1580436.

    +1 @author.  The patch does not contain any @author tags.

    +1 tests included.  The patch appears to include 3 new or modified tests.

    +1 javadoc.  The javadoc tool did not generate any warning messages.

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

    +1 findbugs.  The patch does not introduce any new Findbugs (version 1.3.9) warnings.

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

    -1 core tests.  The patch failed core unit tests.

    +1 contrib tests.  The patch passed contrib unit tests.

Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/1981//testReport/
Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/1981//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/1981//console

This message is automatically generated.

> [JDK8] Sort children for comparison in AsyncOps tests
> -----------------------------------------------------
>
>                 Key: ZOOKEEPER-1901
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1901
>             Project: ZooKeeper
>          Issue Type: Bug
>            Reporter: Andrew Purtell
>            Priority: Minor
>         Attachments: ZOOKEEPER-1901.patch
>
>
> AsyncOpsTest, ChrootAsyncTest, and NioNettySuiteTest can fail running on Java 8 if child znodes are not added to a list in the same order as expected. 
> For example
> {noformat}
> Testcase: testAsyncGetChildrenTwo took 0.166 sec
>         FAILED
> expected:<OK:/foo:[child[1, child2]]> but was:<OK:/foo:[child[2, child1]]>
> junit.framework.AssertionFailedError: expected:<OK:/foo:[child[1, child2]]> but was:<OK:/foo:[child[2, child1]]>
>         at org.apache.zookeeper.test.AsyncOps$AsyncCB.verify(AsyncOps.java:113)
>         at org.apache.zookeeper.test.AsyncOps$ChildrenCB.verify(AsyncOps.java:298)
>         at org.apache.zookeeper.test.AsyncOps$ChildrenCB.verifyGetChildrenTwo(AsyncOps.java:287)
>         at org.apache.zookeeper.test.AsyncOpsTest.testAsyncGetChildrenTwo(AsyncOpsTest.java:155)
>         at org.apache.zookeeper.JUnit4ZKTestRunner$LoggedInvokeMethod.evaluate(JUnit4ZKTestRunner.java:52)
> {noformat}
> {noformat}
> Testcase: testAsyncGetChildren2Two took 0.154 sec
>         FAILED
> expected:<OK:/foo:[child[1, child2]]> but was:<OK:/foo:[child[2, child1]]>
> junit.framework.AssertionFailedError: expected:<OK:/foo:[child[1, child2]]> but was:<OK:/foo:[child[2, child1]]>
>         at org.apache.zookeeper.test.AsyncOps$AsyncCB.verify(AsyncOps.java:113)
>         at org.apache.zookeeper.test.AsyncOps$Children2CB.verify(AsyncOps.java:383)
>         at org.apache.zookeeper.test.AsyncOps$Children2CB.verifyGetChildrenTwo(AsyncOps.java:372)
>         at org.apache.zookeeper.test.AsyncOpsTest.testAsyncGetChildren2Two(AsyncOpsTest.java:175)
> 	at org.apache.zookeeper.JUnit4ZKTestRunner$LoggedInvokeMethod.evaluate(JUnit4ZKTestRunner.java:52)
> {noformat}
> This seems like a test only issue because getChildren javadoc says "The list of children returned is not sorted and no guarantee is provided as to its natural or lexical order." So, fix the tests by sorting the incoming lists. 



--
This message was sent by Atlassian JIRA
(v6.2#6252)