aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/sonar-jacoco-plugin
diff options
context:
space:
mode:
authorEvgeny Mandrikov <mandrikov@gmail.com>2012-09-26 22:38:07 +0600
committerEvgeny Mandrikov <mandrikov@gmail.com>2012-09-26 22:38:07 +0600
commitd999cece595da7c843de473fae9cc0631169a7fc (patch)
tree132612d5e966e08f05cd23078650e6380f3f77ce /plugins/sonar-jacoco-plugin
parent89225e5b64e44bab8fa128c298e7029e418431ea (diff)
downloadsonarqube-d999cece595da7c843de473fae9cc0631169a7fc.tar.gz
sonarqube-d999cece595da7c843de473fae9cc0631169a7fc.zip
SONAR-3827 JaCoCo should use only class files for analysis
Diffstat (limited to 'plugins/sonar-jacoco-plugin')
-rw-r--r--plugins/sonar-jacoco-plugin/src/main/java/org/sonar/plugins/jacoco/AbstractAnalyzer.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/plugins/sonar-jacoco-plugin/src/main/java/org/sonar/plugins/jacoco/AbstractAnalyzer.java b/plugins/sonar-jacoco-plugin/src/main/java/org/sonar/plugins/jacoco/AbstractAnalyzer.java
index 47d6684790e..ca4542faae0 100644
--- a/plugins/sonar-jacoco-plugin/src/main/java/org/sonar/plugins/jacoco/AbstractAnalyzer.java
+++ b/plugins/sonar-jacoco-plugin/src/main/java/org/sonar/plugins/jacoco/AbstractAnalyzer.java
@@ -19,8 +19,6 @@
*/
package org.sonar.plugins.jacoco;
-import org.sonar.api.resources.ResourceUtils;
-
import com.google.common.annotations.VisibleForTesting;
import com.google.common.base.Strings;
import org.apache.commons.lang.StringUtils;
@@ -34,6 +32,7 @@ import org.sonar.api.measures.CoverageMeasuresBuilder;
import org.sonar.api.measures.Measure;
import org.sonar.api.resources.JavaFile;
import org.sonar.api.resources.Project;
+import org.sonar.api.resources.ResourceUtils;
import org.sonar.api.utils.SonarException;
import java.io.File;
@@ -127,7 +126,7 @@ public abstract class AbstractAnalyzer {
for (File f : file.listFiles()) {
analyzeAll(analyzer, f);
}
- } else {
+ } else if (file.getName().endsWith(".class")) {
try {
analyzer.analyzeAll(file);
} catch (Exception e) {