Skip to content
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

Different Coverage Numbers Based On Test Run Order #3899

Open
thunklife opened this issue Dec 12, 2024 · 1 comment
Open

Different Coverage Numbers Based On Test Run Order #3899

thunklife opened this issue Dec 12, 2024 · 1 comment

Comments

@thunklife
Copy link

I have some tests that are producing different coverage numbers based on the order in which the tests are run.

I have components A and B; B is a dependency of A. If I run the tests for A then the tests for B, I get the coverage number for A that I expect but not for B; I get a much lower coverage number for B. However, if I reverse the order I get the order I get the coverage numbers I expect for A and B.

I believe this is because A uses some of the code in B so if it runs first the coverage for B is based on how A is using it. When the tests for B is run the coverage has already been calculated. This makes to me and matches what I am seeing. I am just wondering if this behavior is correct.

Sorry for the lack of actual code but I can't post it for proprietary reasons. I hope my descriptions makes sense. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
@thunklife and others