Uploaded image for project: 'odlparent'
  1. odlparent
  2. ODLPARENT-27

PowerMock tests aren't accounted for in JaCoCo coverage

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Won't Do
    • None
    • None
    • General
    • None
    • Operating System: All
      Platform: All

    • 4941

    Description

      Despite the version hold on JaCoCo, PowerMock tests don't appear in the coverage results; for example https://sonar.opendaylight.org/drilldown/measures/12541?metric=coverage&rids[]=15639&rids[]=45971 currently shows 0.1% coverage in NeutronL3Adapter, yet the test code covers over 60% of that class (as measured independently using IntelliJ and JaCoCo).

      The latest version of PowerMock (1.6.4) is supposed to fix this, but apparently doesn't. https://git.opendaylight.org/gerrit/#/c/32427/ shows how to instrument the code so it gets measured correctly. That unfortunately causes a number of "class already instrumented" errors to be logged, so it feels sub-optimal.

      I'm investigating whether the latest version of JaCoCo (which would involve a Sonar plugin upgrade) fixes things.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              rovarga Robert Varga
              skitt Stephen Kitt
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: