SonarCloud is excluding the code under src/test during the automatic analysis
- Added 2 Java classes under src/main/java/com/
- Added 3 Test Java classes under src/test/java/com/
SonarCloud is excluding the code under src/test during the automatic analysis
Hey there.
Using Automatic Analysis for Java, it’s not possible to override sonar.sources
, sonar.inclusions
or sonar.test.inclusions
to analyze Test code as Source code.
While Automatic Analysis is a great way to get quick results, we suggest switching to CI-based analysis eventually, which will give you more flexibility (such as indexing test code as source code) (usually as simple as widening sonar.sources=src/main/java
to sonar.sources=src/
)