-
-
Notifications
You must be signed in to change notification settings - Fork 437
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Combine coverage files without deleting combined files #1108
Comments
This seems like a simple enough option to add. But I am curious: why not generate the individual reports first from the separate data files, and then combine them to produce the combined report? |
I didn't write it in my original post but the reason is because I am using GNUmake to coordinates the build steps. So from a GNUmake point of view once the coverages files exists it triggers the next targets which depend on them:
Step 2 fail because of step 1 |
Related to nedbat#1108
Related to nedbat#1108
* Add combine --keep Related to #1108 * Fix unit tests * Fix line too long * Fix line too long
This has been implemented in #1110 |
This is now released as part of coverage 5.5. |
Is your feature request related to a problem? Please describe.
When using the combine feature, a combined coverage file is created and💥 the original files are deleted
Describe the solution you'd like
I would like the original files to be kept untouched (do not delete them)
Or have a command line argument to tell combine to keep the original coverage files
Describe alternatives you've considered
alternative # 1 is to create backup copy of the original coverage files somewhere else (temp folder) combine them there and bring back the combined file.
Alternative # 2 is to create a backup copy somewhere else of the original coverage files, combine, copy the originals back after
Alternative # 3 Run all test twice to avoid the need to combine coverage files
Alternative # 4 wait till the coverage files are no more needed before doing combine
Note: I don't like any of the above alternatives hack
Additional context
Here is my use case:
1- I run different kind of test (unit tests, integration tests, smoke tests, ...)
2- I then obtain a coverage file for each of them (unittest.coverage, integrationtest.coverage, smoketest.coverage)
3- I combine them into a alltest.coverage
4- I successfully obtain the alltest.coverage but 💥Oups!; the original unittest.coverage, integrationtest.coverage, smoketest.coverage, etc are gone (they have been deleted by the combine)
5- 💥 I want to use the coverage files of each test types for further processing but their coverage files are gone.
The text was updated successfully, but these errors were encountered: