Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Store relative file paths in the data file
By default, coverage data contains absolute paths for the test suite. During CI, coverage data from various runners is combined in an environment where these paths do not exist. This results in errors like the following: No source for code: '/Users/runner/work/cookiecutter-hypermodern-python-instance/cookiecutter-hypermodern-python-instance/tests/__init__.py'. Aborting report output, consider using -i. The `coverage.paths` setting does not help with the test suite: Unlike the code under `src`, the test suite is not installed to `site-packages`, so we'd need to either hardcode paths from individual runners, or use overly generic wildcards. Instead, `coverage.run.relative_files` can be used to store the paths relative to the repository. We still need `coverage.paths` for `src` though, because these file paths still include the path into the various Nox environments.
- Loading branch information