-
Notifications
You must be signed in to change notification settings - Fork 3
Instrumenting code on every iteration (CI)
If you wish to get coverage report for each build, on each new merge along with running your tests, then you need to remember couple of things:
- newly cloned code must be instrumented again
- test coverage session created after that must have a totally new build number assigned.
explanation:
If you instrument a new code, then source file lines will have new guid numbers that are different from what's already stored in DB. If you create a test coverage session with existing build number, you'll get a false build coverage report containing more than 1 set of stats for each file:
That's because coverage session that already exist for build has stats for some file and new session with the same build also, but with different line GUIDs. Normally when generating build report, duplicated line guids are ignored and coverage for file across all builds is shown. In this case, false coverage for file is shown because there aren't any duplicates but new line guids coming from new instrumentation.
To avoid that (build coverage >100%):
simply remember 2 steps from above.
- How it works
- Initial setup
- Setup for Unity game
- Setup for Android app
- Setup for javascript
- Setup for Angular app
- GETTING THE COVERAGE
- Getting coverage for build (multiple coverage sessions consolidated
- Setup modules
- Managing tags
- Managing users
- Create and End test session automatically (CI)
- Instrumenting code on every iteration
- Coverage report explained
- Accessing latest report
- How to interpret covered lines report
- Config explained
- Settings
- Send custom values along with line statistics
- Examples
- Extended-CI-use-case
- Troubleshooting