We have successfully implemented Jenkins/SonarQube to enforce a requirement that any new code committed by developers must have at least 70% unit test code coverage for Java. However, when it comes to applying the same rule for JavaScript, we encountered some challenges.
In order to analyze JavaScript unit tests with SonarQube, one approach is to use an option like the following (extracted from a Jenkins context):
sonar.javascript.jstestdriver.reportsPath=${WORKSPACE}/my-project/generated-reports/jstd
The issue lies in the fact that using JSTestDriver (https://code.google.com/p/js-test-driver/) is not feasible due to its outdated nature and lack of compatibility with modern JavaScript frameworks like AngularJS or ReactJS.
Have you come across this dilemma before? If so, how did you solve it?