SONARJAVA-255 Improve test