You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by "Chris Douglas (JIRA)" <ji...@apache.org> on 2008/07/02 00:14:45 UTC
[jira] Updated: (HADOOP-3611) TestNetworkTopology could be cleaned
up slightly
[ https://issues.apache.org/jira/browse/HADOOP-3611?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chris Douglas updated HADOOP-3611:
----------------------------------
Resolution: Won't Fix
Status: Resolved (was: Patch Available)
bq. (a) has some of its private static final modifiers in the wrong order
According to the [language spec|http://java.sun.com/docs/books/jls/third_edition/html/classes.html#8.3.1], it is "customary, though not required" that they appear in some order, but there's no semantic relevance; this "custom" is violated in the very next example in the spec, so enforcing it in test code scarcely seems worth it.
bq. (b) in an assertEquals, has the static and dynamic values wrong, so the error message won't be correct
This might be worth fixing- one almost always needs to examine the assertion in the test to know how the test failed, and there the context is unambiguous- but surely there are other examples in the unit tests of this. An omnibus bug (an omnibug?) fixing many instances of "backwards" asserts might be helpful, but this particular fix strikes me as unnecessary. There are at least four other examples of this in TestNetworkTopology alone that remain inverted.
I'm opening HADOOP-3679 to track (b) more generally and closing this.
> TestNetworkTopology could be cleaned up slightly
> ------------------------------------------------
>
> Key: HADOOP-3611
> URL: https://issues.apache.org/jira/browse/HADOOP-3611
> Project: Hadoop Core
> Issue Type: Bug
> Components: test
> Affects Versions: 0.18.0
> Reporter: Steve Loughran
> Assignee: Steve Loughran
> Priority: Minor
> Attachments: TestNetworkTopology.patch
>
>
> The TestNetworkTopology test
> (a) has some of its private static final modifiers in the wrong order
> (b) in an assertEquals, has the static and dynamic values wrong, so the error message won't be correct
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.