Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-4201

Tests in ReflectTest fail when executed with sonar

    XMLWordPrintable

    Details

    • Complexity:
      Undetermined

      Description

      Sonar executes tests with instrumented classes, thus we see errors like:

      junit.framework.ComparisonFailure: expected:<[nonCollectionField]> but was:<[$jacocoData]>
      	at junit.framework.Assert.assertEquals(Assert.java:100)
      	at junit.framework.Assert.assertEquals(Assert.java:107)
      	at org.openmrs.util.ReflectTest.isCollection_shouldReturnFalseIfGivenFieldClassIsNotACollectionClass(ReflectTest.java:86)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:622)
      (23 more lines...)
      

        Gliffy Diagrams

          Attachments

            Activity

              People

              Assignee:
              raff Rafal Korytkowski
              Reporter:
              raff Rafal Korytkowski
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: