This project shows how to collect code coverage from Storybook (e.g. when using Chromatic for Visual Regresion tests) and how to create a combined report for 3 types of test:
- visual regression tests (storybook/chromatic)
- unit tests (jest)
- integration tests (cypress)
You can view a report for each type of test, or view the coverage of all tests together.
yarn yarn coverage open coverage/merged/lcov-report/index.htmlYou can also merge reports with codecov.
- Integration test report doesn't include files with no coverage cypress-io/code-coverage#194
- Can't configure cypress-specific nyc settings outside of package.json (tbc)
- Can't currently use create-react-app 3.4.1 - facebook/create-react-app#8689
- setting
"reporter": ["text", "lcov"]in nyc settings causes cypress code coverage to crash