You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Kristian Waagan (JIRA)" <ji...@apache.org> on 2012/06/14 10:06:42 UTC

[jira] [Created] (DERBY-5817) Add support for the JaCoCo code coverage tool

Kristian Waagan created DERBY-5817:
--------------------------------------

             Summary: Add support for the JaCoCo code coverage tool
                 Key: DERBY-5817
                 URL: https://issues.apache.org/jira/browse/DERBY-5817
             Project: Derby
          Issue Type: Task
          Components: Miscellaneous, Test
    Affects Versions: 10.10.0.0
            Reporter: Kristian Waagan
            Assignee: Kristian Waagan
            Priority: Minor


Add support for the JaCoCo code coverage tool ([1]).
While we are currently relying on EMMA for code coverage, the tool isn't being maintained. It works nicely for the time being, but having additional support for a tool that's being actively developed and maintained would be nice.

[1] http://www.eclemma.org/jacoco/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (DERBY-5817) Add support for the JaCoCo code coverage tool

Posted by "Kristian Waagan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-5817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kristian Waagan updated DERBY-5817:
-----------------------------------

    Attachment: derby-5817-1c-jacoco_support.diff

Attaching patch 1c, which further improves the JaCoCo support in build.xml.

I refactored some code related to getting the svn version, because I'm adding the version to the report title.

I updated the report at people.apache.org/~kristwaa/jacoco/ with the results produced by patch 1c and the target jacoco-complete.

I think the EMMA results include coverage data from runs with several different JVM versions. I have not added support for that, but assuming the merged.exec file is kept from each run a separate merge/report target can be used.

Patch ready for review.
                
> Add support for the JaCoCo code coverage tool
> ---------------------------------------------
>
>                 Key: DERBY-5817
>                 URL: https://issues.apache.org/jira/browse/DERBY-5817
>             Project: Derby
>          Issue Type: Task
>          Components: Miscellaneous, Test
>    Affects Versions: 10.10.0.0
>            Reporter: Kristian Waagan
>            Assignee: Kristian Waagan
>            Priority: Minor
>         Attachments: derby-5817-1a-jacoco_support.diff, derby-5817-1b-jacoco_support.diff, derby-5817-1c-jacoco_support.diff
>
>
> Add support for the JaCoCo code coverage tool ([1]).
> While we are currently relying on EMMA for code coverage, the tool isn't being maintained. It works nicely for the time being, but having additional support for a tool that's being actively developed and maintained would be nice.
> [1] http://www.eclemma.org/jacoco/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (DERBY-5817) Add support for the JaCoCo code coverage tool

Posted by "Kristian Waagan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-5817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kristian Waagan resolved DERBY-5817.
------------------------------------

       Resolution: Fixed
    Fix Version/s: 10.10.0.0

Committed patch 1c to trunk with revision 1352502.

This concludes the initial work on adding support for JaCoCo. Further improvements can be tracked under their own JIRAs.
                
> Add support for the JaCoCo code coverage tool
> ---------------------------------------------
>
>                 Key: DERBY-5817
>                 URL: https://issues.apache.org/jira/browse/DERBY-5817
>             Project: Derby
>          Issue Type: Task
>          Components: Miscellaneous, Test
>    Affects Versions: 10.10.0.0
>            Reporter: Kristian Waagan
>            Assignee: Kristian Waagan
>            Priority: Minor
>             Fix For: 10.10.0.0
>
>         Attachments: derby-5817-1a-jacoco_support.diff, derby-5817-1b-jacoco_support.diff, derby-5817-1c-jacoco_support.diff
>
>
> Add support for the JaCoCo code coverage tool ([1]).
> While we are currently relying on EMMA for code coverage, the tool isn't being maintained. It works nicely for the time being, but having additional support for a tool that's being actively developed and maintained would be nice.
> [1] http://www.eclemma.org/jacoco/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (DERBY-5817) Add support for the JaCoCo code coverage tool

Posted by "Kristian Waagan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-5817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kristian Waagan updated DERBY-5817:
-----------------------------------

    Attachment: derby-5817-1a-jacoco_support.diff

Attaching patch 1a, which adds support for JaCoCo.

The change in build.xml enables JaCoCo, and the change in BaseTestCase ensure that JaCoCo will also be enabled in spawned Java processes (as for EMMA).

There are two new top-level targets, based on junit-all and junit-single:
 jacoco-all
 jacoco-single

You have to download JaCoCo and place the two jar files jacocoant.jar and jacocoagent.jar in tools/java. The targets above will complain if these files are missing.

When running jacoco-all I'm still seeing one error, which appears to be a problem with ASM, which is used by JaCoCo. I'll see if I can find any more information on this issue. The error doesn't cause the run to be aborted, and the coverage data appears ok.
The report ends up in junit_{timestamp}/coverage-report.

Patch ready for review.
                
> Add support for the JaCoCo code coverage tool
> ---------------------------------------------
>
>                 Key: DERBY-5817
>                 URL: https://issues.apache.org/jira/browse/DERBY-5817
>             Project: Derby
>          Issue Type: Task
>          Components: Miscellaneous, Test
>    Affects Versions: 10.10.0.0
>            Reporter: Kristian Waagan
>            Assignee: Kristian Waagan
>            Priority: Minor
>         Attachments: derby-5817-1a-jacoco_support.diff
>
>
> Add support for the JaCoCo code coverage tool ([1]).
> While we are currently relying on EMMA for code coverage, the tool isn't being maintained. It works nicely for the time being, but having additional support for a tool that's being actively developed and maintained would be nice.
> [1] http://www.eclemma.org/jacoco/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (DERBY-5817) Add support for the JaCoCo code coverage tool

Posted by "Kristian Waagan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-5817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kristian Waagan updated DERBY-5817:
-----------------------------------

    Attachment: derby-5817-1b-jacoco_support.diff

Attaching patch 1b, which also adds a derbyall target.

Needs some additional testing, but feel free to provide feedback.
Not quite sure what to do about junit-pptesting yet, since it requires the classes-directory to be present. I'll probably move it away from junit-all and run it explicitly.

With this patch the coverage increased with about 2 percent. The compatibility test is still not included (I want rewrite it first ;) ).
                
> Add support for the JaCoCo code coverage tool
> ---------------------------------------------
>
>                 Key: DERBY-5817
>                 URL: https://issues.apache.org/jira/browse/DERBY-5817
>             Project: Derby
>          Issue Type: Task
>          Components: Miscellaneous, Test
>    Affects Versions: 10.10.0.0
>            Reporter: Kristian Waagan
>            Assignee: Kristian Waagan
>            Priority: Minor
>         Attachments: derby-5817-1a-jacoco_support.diff, derby-5817-1b-jacoco_support.diff
>
>
> Add support for the JaCoCo code coverage tool ([1]).
> While we are currently relying on EMMA for code coverage, the tool isn't being maintained. It works nicely for the time being, but having additional support for a tool that's being actively developed and maintained would be nice.
> [1] http://www.eclemma.org/jacoco/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira