It seems that the JavaPlugin adds a test.doFirst which puts the classes
directory in the unmanaged classpath.

Thus I did the following (using the cobertura ant task):

test.doFirst {
    delete cobertura.ser and classesDir copy (if they exist)
    if (cobertura installation found) {
        copy classesDir to classesDir copy
        instrument classesDir (in place) with cobertura
        add cobertura.jar to test's unmanaged classpath
    }
}

test.doLast {
    if classesDir copy exists {
        delete classesDir
        move classesDir copy to classesDir
        do cobertura report(s)
    }
}

All this (and findbugs and PMD) is in an included configuration file.
Each project has it's basic build file (which includes the configuration
file) and automatically findbugs, PMD and cobertura are used - and the
results and their history are visible on our continuous build server.
-- 
View this message in context: 
http://www.nabble.com/Testing-instrumented-classes--tp20247149p20299915.html
Sent from the gradle-user mailing list archive at Nabble.com.


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

    http://xircles.codehaus.org/manage_email


Reply via email to