You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Prystash,John" <pr...@oclc.org> on 2008/02/29 01:20:43 UTC

Cobetura Reporting and Groovy

Hey Everyone, I've added Groovy to project and am trying to get the
source viewable from my Cobertura report.  The Groovy gets a coverage
rating, but on the generated report I get the following when trying to
view the source for a file.

Unable to locate org/oclc/MyApp/Hello.groovy. Have you specified the
source directory? 

Running mvn -e site-deploy outputs:

[cobertura] INFO  [main]
net.sourceforge.cobertura.reporting.ComplexityCalculator - Cannot find
source file during CCN computation, source=[org/oclc/MyApp/Hello.groovy]

I'm thinking I'm missing a goal, but other then the ones shown, I'm not
sure.
The relevant sections from my POM:

     <plugin>
        <groupId>org.codehaus.mojo.groovy</groupId>
        <artifactId>groovy-maven-plugin</artifactId>
        <version>1.0-beta-3</version>
        <extensions>true</extensions>
        <executions>
          <execution>
            <goals>
              <!--<goal>generateStubs</goal>-->
              <goal>compile</goal>
              <!--<goal>generateTestStubs</goal>-->
              <goal>testCompile</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

   <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.3</version>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>cobertura-maven-plugin</artifactId>
        <version>2.2</version>
      </plugin>
   </reporting>

Thanks