Excluding a (Java) file from coverage using sonar.coverage.exclusions should make the file completely excluded from coverage measures. But since 6.4, and when exclusion is applied at module level, the file will have a coverage counted as zero.
We changed ZeroCoverageSensor to a global Sensor. The problem is that it relies on CoverageExclusions component, that read settings of the current module (so only root module = project here).
I think we should change CoverageExclusions to collect exclusions for every modules, so that at the end we get the complete list of excluded files.
Workaround: coverage exclusions declared at project level (either in UI or on scanner side) are correctly taken into account.