code-coverage icon indicating copy to clipboard operation
code-coverage copied to clipboard

Cobertura file not created despite out.json is

Open fasatrix opened this issue 6 years ago • 8 comments

Context

Hi, I have instrumented the code using the following command:

npx nyc instrument --compact=false src instrumented

and to be practical I have moved the instrumented folder into src (esier) and I have committed everything into the following repository: https://github.com/fasatrix/nyc-test-folder-outside-src

Please install both package.json. The one in the root and the other within the test folder

To run the tests use npm run cypress:run script

Current behavior:

Despite the out.json file has been create in .nyc_output, cobertura and other coverage types are being created empty

Desired behavior:

Cobertura and other coverage types should be created

Steps to reproduce: (app code and test code)

Just clone the repo, install dependencies, run the the app and the test

Additional Notes

If I use the standard configuration and keep the "Cypress" folder at the same level as the src one everything works fine (repo for reference below). However for the project project I am working on (These are demos with the structure as the actual project which is confidential) I am unable to use this working configuration as I need to keep all test types(performance, e2e, cross browsers eyc.) within the test folder

https://github.com/fasatrix/nyc-test-folder-inside-src

Versions

Win 10 Cypress 3.4

fasatrix avatar Oct 08 '19 19:10 fasatrix

@jennifer-shehane , is anybody free/able to look into this please? Thanks a lot

fasatrix avatar Oct 13 '19 20:10 fasatrix

Hi @bahmutov I know you guys very busy but it's there any chance anyone can look into this briefly? Much appreciated. Thanks alot

fasatrix avatar Oct 29 '19 19:10 fasatrix

Hi @bahmutov does version 1.10.2 solve the problem explained in this issue as highlighted in hte following thread? Thanks

https://github.com/cypress-io/code-coverage/issues/73#issuecomment-554074327

fasatrix avatar Nov 15 '19 00:11 fasatrix

Try it - I don’t know since I don’t have a reproduction

Sent from my iPhone

On Nov 14, 2019, at 19:59, Fabio Santoro [email protected] wrote:

 Hi @bahmutov does version 1.10.2 solve the problem explained in this issue as highlighted in hte following thread? Thanks

cypress-io/code-coverage#73 (comment)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

bahmutov avatar Nov 15 '19 01:11 bahmutov

Closing this because the issue is old and the example isn't reproducible. If the problem is still happening, please open a new issue with a reproducible example.

sainthkh avatar Jan 04 '21 08:01 sainthkh

@sainthkh it was reproducible I spent quite a bit of time to create the two repos... someone had just to spend some time and try it.. Your choice though!

fasatrix avatar Jan 06 '21 00:01 fasatrix

I couldn't reproduce it because I ran it on Ubuntu. But I need to think about the cause and what tags I should use for this.

sainthkh avatar Jan 06 '21 01:01 sainthkh

I should move it to our code-coverage repo

Sent from my iPhone

On Jan 5, 2021, at 20:25, Fabio Santoro [email protected] wrote:

 I couldn't reproduce it because I ran it on Ubuntu. But I need to think about the cause and what tags I should use for this.

Apologies in advance but this sounds like a poor response from a company that promotes a product

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

bahmutov avatar Jan 06 '21 01:01 bahmutov