istanbuljs / nyc

the Istanbul command line interface
https://istanbul.js.org/
ISC License
5.6k stars 359 forks source link

Vue files are not getting instrumented properly #1463

Open scaricopax8 opened 2 years ago

scaricopax8 commented 2 years ago

Link to bug demonstration repository

Vue 3 https://github.com/scaricopax8/nyc-vue-3

Vue 2 https://github.com/scaricopax8/nyc-vue-2

Expected Behavior

When running the nyc instrument --compact=false src instrumented command, the Vue files in the newly created instrumented folder are properly instrumented.

Observed Behavior

When running the nyc instrument --compact=false src instrumented command, the Vue files are generated in the instrumented folder, but unlike their .js counterparts, they are not instrumented

Troubleshooting steps

Environment Information

  System:
    OS: macOS 12.3.1
    CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
    Memory: 85.71 MB / 32.00 GB
  Binaries:
    Node: 14.16.1 - ~/.nvm/versions/node/v14.16.1/bin/node
    npm: 6.14.15 - ~/.nvm/versions/node/v14.16.1/bin/npm
  npmPackages:
    @vue/cli-plugin-babel: ~4.5.15 => 4.5.17
    babel-eslint: ^10.1.0 => 10.1.0
    nyc: ^15.1.0 => 15.1.0
didagu commented 2 years ago

@scaricopax8 I am having the same problem. did you find any solution yet ?