[ http://jira.codehaus.org/browse/MPCLOVER-47?page=comments#action_64228 ]
Lukas Theussl commented on MPCLOVER-47: --------------------------------------- Wim, I think I finally figured this one out: the reason why clover doesn't work after aspectj is that ant's iajc task is configured by default to compile aspect .aj *and* java sources. When the javac task runs afterwards, it sees an up-to-date .class file of the java source file and skips another compilation. But clover is configured to run only on javac-generated sources. So I think the solution is simply to tell aspectj to only compile .aj source files: setting maven.aspectj.src.argfilesOnly=true for your test project gives me the clover report. However, I don't know if this is a workable solution for you, also the argfilesOnly property does not seem to be documented on the properties page of the aspectj plugin, I will add that shortly. > Clover report is not generated when using Maven AspectJ plugin > -------------------------------------------------------------- > > Key: MPCLOVER-47 > URL: http://jira.codehaus.org/browse/MPCLOVER-47 > Project: maven-clover-plugin > Type: Bug > Versions: 1.10 > Environment: Maven 1.0.2 on Windows XP > Reporter: Glauber VinÃcius Ferreira > Priority: Blocker > Attachments: Introduction Example.zip, aspectjtest.zip > > > When I am using AspectJ plugin with this lines in my maven.xml file: > <preGoal name="java:compile"> > <attainGoal name="aspectj"/> > </preGoal> > the Clover report is not generated. The following message is presented: > clover:report: > [echo] No Clover database found, skipping report generation > The folder "target\clover\database" stays empty. > -------------------------------------------------------------------------------------------------- > When I am using AspectJ plugin with this lines in my maven.xml file: > <preGoal name="java:compile"> > <attainGoal name="aspectj:compile"/> > </preGoal> > an empty Clover report is generated, although there is one test in the > project. The following message is presented: > [clover-report] No coverage data found for 'C:\eclipse\workspace\Introduction > Example\target\clover\database\clover_coverage.db'. > The file "clover_coverage.db" is created at folder "target\clover\database" > -------------------------------------------------------------------------------------------------- > When I am using AspectJ plugin with no preGoal for "java:compile" the Clover > report is generated properly. > -------------------------------------------------------------------------------------------------- > The MPCLOVER-27 issue reports this same problem, but did not provide data to > reproduce it. > Thank you. -- 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