-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Description
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.