Skip to content
This repository was archived by the owner on Feb 8, 2019. It is now read-only.

Example to reproduce issue2 with istanbul-api#1

Open
lo1tuma wants to merge 1 commit intoistanbuljs:masterfrom
lo1tuma:reproduce-api-issue2
Open

Example to reproduce issue2 with istanbul-api#1
lo1tuma wants to merge 1 commit intoistanbuljs:masterfrom
lo1tuma:reproduce-api-issue2

Conversation

@lo1tuma
Copy link

@lo1tuma lo1tuma commented Jan 25, 2016

This change executes the check-coverage command in order to reproduce istanbuljs-archived-repos/istanbul-api#2.

After running npm test you can see the the result from check-coverage differs from the coverage summary:

$ npm test

> sample-mocha-compilers@1.0.0 test /Users/foo/workspace/sample-mocha-compilers
> istanbul cover _mocha -- --compilers js:babel-core/register test/



  rectangle
    ✓ calculates area


  1 passing (404ms)


=============================== Coverage summary ===============================
Statements   : 83.33% ( 10/12 )
Branches     : 50% ( 2/4 )
Functions    : 100% ( 1/1 )
Lines        : 83.33% ( 10/12 )
================================================================================

> sample-mocha-compilers@1.0.0 posttest /Users/foo/workspace/sample-mocha-compilers
> istanbul check-coverage


/Users/foo/workspace/sample-mocha-compilers/node_modules/istanbul/lib/cli.js:38
        throw ex; // turn it into an uncaught exception
        ^
ERROR: Coverage for statements (84.38%) does not meet global threshold (100%)
ERROR: Coverage for branches (57.14%) does not meet global threshold (100%)
ERROR: Coverage for lines (88.89%) does not meet global threshold (100%)
npm ERR! Test failed.  See above for more details.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant