Geronimo
  1. Geronimo
  2. GERONIMO-3672

org.apache.geronimo.j2ee.deployment.annotation.AnnotationHelperTest is implementation-dependent

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.2
    • Fix Version/s: 2.0.3, 2.1
    • Component/s: testsuite
    • Security Level: public (Regular issues)
    • Labels:
      None

      Description

      Test org.apache.geronimo.j2ee.deployment.annotation.AnnotationHelperTest may fail on non-Sun implementation, because it assumes the order in which Class.getFields() returns the fields, while specification doesn't specify the particular order.

      The problem occurs in method PersistenceUnitAnnotationHelper.processPersistenceUnit() which gets the fields and adds them to the annotatedApp, that is later compared (in the tests themselves) with expected XML - at this point the tests may as the order of elements in the resulting XML may be different.

      The following assertions fail on Apache Harmony because of this fact:
      testPersistenceContextAnnotationHelper
      testPersistenceUnitAnnotationHelper
      testWebServiceRefAnnotationHelper

        Activity

        Vasily Zakharov created issue -
        Jarek Gawor made changes -
        Field Original Value New Value
        Assignee Jarek Gawor [ gawor@mcs.anl.gov ]
        Hide
        Jarek Gawor added a comment -

        Fixed the tests in trunk (revision 601205).

        Show
        Jarek Gawor added a comment - Fixed the tests in trunk (revision 601205).
        Hide
        Jarek Gawor added a comment -

        Fixed tests in branches/2.0 (revision 601208).

        Show
        Jarek Gawor added a comment - Fixed tests in branches/2.0 (revision 601208).
        Jarek Gawor made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.1 [ 12312602 ]
        Fix Version/s 2.0.x [ 12312601 ]
        Hide
        Vasily Zakharov added a comment -

        Thanks, Jarek, that fixes the problem!

        Closing the issue.

        Show
        Vasily Zakharov added a comment - Thanks, Jarek, that fixes the problem! Closing the issue.
        Vasily Zakharov made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Joe Bohn made changes -
        Fix Version/s 2.0.x [ 12312601 ]
        Fix Version/s 2.0.3 [ 12313315 ]

          People

          • Assignee:
            Jarek Gawor
            Reporter:
            Vasily Zakharov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development