Vue-jest: Istanbul ignore comments

Created on 11 Jan 2018  路  6Comments  路  Source: vuejs/vue-jest

When using vue-jest as transformer for .vue files istanbul ignore comments like /* istanbul ignore next*/ doesn't take effect on coverage.

Most helpful comment

This is fixed in v4, which I will release as a beta later today

All 6 comments

Thanks for the bug report.

What's your config (like babel config)?

{
  "comments": false,
  "presets": [
    "es2015",
    "stage-2",
    "stage-0",
    ["env", { "modules": false}]
  ],
  "plugins": ["transform-runtime"],
  "env": {
    "test": {
      "presets": ["env", "stage-2"]
    }
  }
}

Any news on this @eddyerburgh ?

Not yet sorry @rmartins90

Found out that if I use babel-plugin-istanbul (https://github.com/istanbuljs/babel-plugin-istanbul) and configure it into .babelrc the ignore isntructions works.

However it returns error in some .js files - https://github.com/istanbuljs/istanbuljs/issues/73. This issue points that the error is caused by double instrumentation.

Maybe this is useful information for you @eddyerburgh .

This is fixed in v4, which I will release as a beta later today

Was this page helpful?
0 / 5 - 0 ratings

Related issues

chenxeed picture chenxeed  路  5Comments

emman27 picture emman27  路  7Comments

AlllenShen picture AlllenShen  路  3Comments

jacobmischka picture jacobmischka  路  8Comments

vincemukiiri picture vincemukiiri  路  9Comments