Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7900434

Incomplete coverage for classes loaded repeteadly

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: jcov_1.1
    • Fix Version/s: jcov_1.1
    • Component/s: tools
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      1.1
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Description



      Name: kbR10066 Date: 01/30/2003


      If an application contains a class loaded via different class loaders several times
      during execution, coverage data is collected only for the first loaded copy.
      For example, if we run the test program from bug#4810478 like this:

      > $JDK140/bin/java -Xrunjcovt:t=m -cp classes a

      then coverage data for the class b (which is loaded twice) will be:

      ---------------------------------
      CLASS: b [public]
      SRCFILE: b.java
      TIMESTAMP: 1043328976233
      DATA: M
      #kind line position count
      METHOD: <init>()V [public]
      1 6 0 2
      METHOD: <clinit>()V [static]
      1 3 0 1
      ---------------------------------

      whereas it should be:

      ---------------------------------
      CLASS: b [public]
      SRCFILE: b.java
      TIMESTAMP: 1043328976233
      DATA: M
      #kind line position count
      METHOD: <init>()V [public]
      1 6 0 3
      METHOD: <clinit>()V [static]
      1 3 0 2
      ---------------------------------

      That is, the actual execution counters are greater than those
      stored in the coverage file.
      ======================================================================

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              afedorch Alexey Fedorchenko (Inactive)
              Reporter:
              klooney Kevin Looney (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: