Customizing <build><testOutputDirectory> creates bad test classpath, giving 0% 
coverage
---------------------------------------------------------------------------------------

                 Key: MCOBERTURA-112
                 URL: http://jira.codehaus.org/browse/MCOBERTURA-112
             Project: Maven 2.x Cobertura Plugin
          Issue Type: Bug
    Affects Versions: 2.3
         Environment: maven 2.0.10, JDK 1.6.0_13-b03
            Reporter: Bob Fields
         Attachments: coberturalog.zip

Change <build><outputDirectory>bin</outputDirectory> (because we run with 
projects originally built in Eclipse standard directory structure, or with test 
sources mixed in with regular classes, with the Eclipse standard class output 
directory). Running mvn -X cobertura:cobertura to get the debug output shows 
the altered test intput classpath entry is placed IN FRONT of the cobertura 
instrumented classes by the surefire plugin test classpath, resulting in 0% 
test coverage. Moving the test output directory to the default maven 
directories (src/main/java and target/classes) results in the cobertura 
instrumented classes first in the classpath, and test coverage measured 
properly. Two debug log files attached, one that works properly and one that 
does not. Notice the 
[DEBUG] Test Classpath :
[DEBUG]   
C:\Programs\ClearCase\rjf3_JavaFoundProj\SharedFoundation\JavaFound\Code\SharedCore\bin
[DEBUG]   
C:\Programs\ClearCase\rjf3_JavaFoundProj\SharedFoundation\JavaFound\Code\SharedCore\target\generated-classes\cobertura
[DEBUG]   rest of the test classpath...

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to