You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.
View groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
Hi,
I'm integrating Clover tests optimization feature into Hadoop core projects and have issue with some tests which are not optimized and included into each tests run with following messages:
[INFO] Including 'org/apache/hadoop/fs/TestFcLocalFsPermission.java' in the test run because Clover cannot correlate it with previously executed test method.
This is only one example there are 46 such classes.
The Clover version 3.0.2 and Maven clover plugin version 3.0.5 are used
What can be the cause of this issue?
Below is profile sample which is defined in parent maven pom :
<profile>
<id>clover.optimize</id>
<activation>
<activeByDefault>false</activeByDefault>
<property>
<name>clover.optimize</name>
</property>
</activation>
<properties>
<cloverLicenseLocation>${user.home}/.clover.license</cloverLicenseLocation>
<clover.snapshot>${project.basedir}/.clover/clover.snapshot</clover.snapshot>
</properties>
<build>
<plugins>
<plugin>
<groupId>com.atlassian.maven.plugins</groupId>
<artifactId>maven-clover2-plugin</artifactId>
<configuration>
<outputDirectory>${project.build.directory}/clover</outputDirectory>
<licenseLocation>${cloverLicenseLocation}</licenseLocation>
<snapshot>${clover.snapshot}</snapshot>
<includesAllSourceRoots>true</includesAllSourceRoots>
<singleCloverDatabase>true</singleCloverDatabase>
<instrumentation>method</instrumentation>
</configuration>
<executions>
<execution>
<id>clover</id>
<goals>
<goal>setup</goal>
<goal>optimize</goal>
<goal>snapshot</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<version>1.4</version>
<executions>
<execution>
<phase>process-test-classes</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<source>
def tests = project.properties['test'];
log.info("Tests to run: " + tests);
if (tests != null && tests.length() == 0) {
log.info("No tests to run");
project.properties['skipTests'] = 'true';
}
</source>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
Hi Dmitry
A debug message:
Including 'org/apache/hadoop/fs/TestFcLocalFsPermission.java' in the test run because Clover cannot correlate it with previously executed test method.
means that information about this test case has not been found in optimization snapshot (new test case?) and thus Clover decided to include it in tests.
Possible reasons:
1) You have run first build without Clover and next second build with -Pclover.optimize without cleaning a workspace. As a result, only a subset of classes was instrumented and registered in clover.db.
2) By default test optimization snapshot is recreated every 10 runs. The TestFcLocalFsPermission is a new class which was created after snapshot creation and as a consequence, snaphsot does not contain information about it.
Solution:
Deleting optimization snapshot and running full test should solve the problem.
Regards
Marek
Back in April of last year one of the major product announcements from Opsgenie was the launch of the Incident investigation view which created a deep connection between Bitbucket and Opsgenie, empow...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.