trautonen / coveralls-maven-plugin

Maven plugin for submitting Java code coverage reports to Coveralls web service.
MIT License
312 stars 125 forks source link

Support for Atlassian Clover #36

Open louiszuckerman opened 10 years ago

louiszuckerman commented 10 years ago

My project, glusterfs-java-filesystem, makes heavy use of PowerMock. As a result, Clover is the only coverage analyzer that works properly. I'd like to send reports to Coveralls and put their status image in my README.

Please consider adding support for Atlassian Clover (https://www.atlassian.com/software/clover).

Thank you in advance.

trautonen commented 9 years ago

Is this still relevant? I haven't added support to Clover due to the fact that the tool is not free. I could ask Atlassian if I can use it for free to add support for the Coveralls maven plugin.

I could use an example coverage report (XML if possible) from Clover to add the support. Could you create a small example with Clover and add it to this issue so I can create a parser for it.

louiszuckerman commented 9 years ago

Yes, still relevant. And Atlassian gives free licenses for open source projects.

I'll post a sample report later today.

Thanks!

louiszuckerman commented 9 years ago

Sorry for the huge delay but here finally is a sample XML report from Clover. I'm not sure if it's a good example, so let me know if you need more.

https://www.dropbox.com/s/cio2la6p00e5b24/clover.xml?dl=0

Regards,

-louis

akshaisarma commented 8 years ago

The v3.2.0 milestone has been released. Which version is this being planned for? I would love to have this supported.

ChristianMurphy commented 7 years ago

Clover has release as open souce https://www.atlassian.com/blog/announcements/atlassian-clover-open-source New documentation home: http://openclover.org

lhazlewood commented 6 years ago

120 is an open PR for this that we've been using for quite a long time as a custom build. Can this please be merged and made official (and released) so we can stop using our custom artifacts?

In the meantime, in case anyone needs this right now, our custom artifact is currently hosted on bintray. You can access it in your maven projects as follows:

Put this in your pom.xml as an direct child somewhere under the <project> element:

<!-- Begin temporary repos until official release of coverall-maven-plugin with clover support -->
<repositories>
    <repository>
        <snapshots>
            <enabled>false</enabled>
        </snapshots>
        <id>bintray-jwtk-coveralls-maven-plugin</id>
        <name>bintray</name>
        <url>https://dl.bintray.com/jwtk/coveralls-maven-plugin</url>
    </repository>
</repositories>
<pluginRepositories>
    <pluginRepository>
        <snapshots>
            <enabled>false</enabled>
        </snapshots>
        <id>bintray-jwtk-coveralls-maven-plugin</id>
        <name>bintray-plugins</name>
        <url>https://dl.bintray.com/jwtk/coveralls-maven-plugin</url>
    </pluginRepository>
</pluginRepositories>
<!-- End temporary repos until official release of coverall-maven-plugin with clover support -->

And then declare in your <build><plugins> section:

<plugin>
    <groupId>org.openclover</groupId>
    <artifactId>clover-maven-plugin</artifactId>
    <version>4.2.1</version>
    <configuration>
        <excludes>
            <!-- We don't care about coverage for test code itself: -->
            <exclude>**/*Test</exclude>
        </excludes>
        <methodPercentage>100%</methodPercentage>
        <statementPercentage>100%</statementPercentage>
        <conditionalPercentage>100%</conditionalPercentage>
        <targetPercentage>100%</targetPercentage>
    </configuration>
    <executions>
        <execution>
            <id>clover</id>
            <phase>test</phase>
            <goals>
                <goal>instrument</goal>
                <goal>check</goal>
                <goal>clover</goal>
            </goals>
        </execution>
    </executions>
</plugin>
<!-- Temporary until official release of coverall-maven-plugin with clover support: -->
<plugin>
    <groupId>org.jwtk.coveralls</groupId>
    <artifactId>coveralls-maven-plugin</artifactId>
    <version>4.4.0</version>
</plugin>
etki commented 5 years ago

Please please please consider @lhazlewood comment above