22.12.2021
The real test coverage with jest
While running your test jest can also collect test coverage information. For this it tracks which parts of your code are actually used while running your tests. Problem is that by default only code that gets at least loaded by your test cases counts into the total possible code coverage. Solution is using collectCoverageFrom. This allows you to tell jest about all your files that should make up the total possible code that should be covered.
Standort Hannover
newcubator GmbH
Bödekerstraße 22
30161 Hannover
Standort Dortmund
newcubator GmbH
Westenhellweg 85-89
44137 Dortmund