commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matt Benson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LANG-727) ToStringBuilderTest.testReflectionHierarchyArrayList fails with IBM JDK 6
Date Tue, 02 Aug 2011 21:22:27 GMT

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

Matt Benson commented on LANG-727:
----------------------------------

I maintain that this test just verifies expectations of the code when running under a certain
set of assumptions, including "the ArrayList implementation in use has an elementData member."
 If we know that that means the Sun JDK, we should just turn the test off under other circumstances.
 It's not like we don't have the vendor info readily available; this _is_ Commons Lang, after
all.

> ToStringBuilderTest.testReflectionHierarchyArrayList fails with IBM JDK 6
> -------------------------------------------------------------------------
>
>                 Key: LANG-727
>                 URL: https://issues.apache.org/jira/browse/LANG-727
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.builder.*
>    Affects Versions: 3.0
>            Reporter: Joerg Schaible
>            Priority: Trivial
>             Fix For: 3.0.1
>
>
> The unit test fails when running with IBM JDK 6:
> {noformat}
> Failed tests: 
>   testReflectionHierarchyArrayList(org.apache.commons.lang3.builder.ToStringBuilderTest): null 
> expected:<....ArrayList@115b115b[[elementData={<null>,<null>,<null>,<null>,<null>,<null>,<null>,null>,null>,null>},size=0],modCount=0]>
> but was:<....ArrayList@115b115b[[firstIndex=0,lastIndex=0,array={<null>,<null>,<null>,<null>,<null>,<null>,<null>,null>,null>,null>}],modCount=0]>
> {noformat}
> Actually the test is wrong, because it makes wrong assumptions about the implementation
of ArrayList in the runtime.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

Mime
View raw message