if (this.codeType != null) {
cloverPassTask.setCodeType(codeType);
}
if (this.targetPercentage != null) {
cloverPassTask.setTarget( new Percentage( this.targetPercentage ) );
getLog().info( "Checking for coverage of [" + targetPercentage + "] for database [" + database + "]");
if (this.methodPercentage != null)
{
cloverPassTask.setMethodTarget(new Percentage(this.methodPercentage));
getLog().info("Checking for method coverage of [" + methodPercentage + "] for database [" + database + "]");
}
if (this.conditionalPercentage != null)
{
cloverPassTask.setConditionalTarget(new Percentage(this.conditionalPercentage));
getLog().info("Checking for conditional coverage of [" + conditionalPercentage + "] for database [" + database + "]");
}
if (this.statementPercentage != null)
{
cloverPassTask.setStatementTarget(new Percentage(this.statementPercentage));
getLog().info("Checking for statement coverage of [" + statementPercentage + "] for database [" + database + "]");
}
} else if (this.historyDir.exists() && this.historyDir.isDirectory()) {
cloverPassTask.setHistorydir(this.historyDir);
cloverPassTask.setThreshold(new Percentage(this.historyThreshold));
getLog().info( "Checking coverage against historical data [" +
this.historyDir + " +/-" + this.historyThreshold +
" ] for database [" + database + "]");
} else {
getLog().warn("Skipping clover2:check as 'maven.clover.targetPercentage' is not defined " +