You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2019/07/22 08:48:33 UTC

[GitHub] [cordova-js] raphinesse opened a new pull request #209: Collect & report test coverage for our browser code

raphinesse opened a new pull request #209: Collect & report test coverage for our browser code
URL: https://github.com/apache/cordova-js/pull/209
 
 
   ### Motivation and Context
   <!-- Why is this change required? What problem does it solve? -->
   <!-- If it fixes an open issue, please link to the issue here. -->
   We haven't had code coverage for our client JS tests for some time. With this PR, running the tests also creates a code coverage report.
   
   
   ### Description
   <!-- Describe your changes in detail -->
   Since our tests are run by `karma`, we use `karma-coverage` to create the code coverage report. However, since we are using a custom module system that is somewhere between RequireJS and CommonJS, we have to do the test code instrumenting ourselves. We use the Istanbul JS API for that. To be as compatible with `karma-coverage` as possible, we do not add `istanbul` to our `devDependencies` but instead, when requiring it, we rely on getting the version of `istanbul` that `karma-coverage` depends on.
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org