Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add unstable --dep-coverage option #353

Merged
merged 1 commit into from
Mar 10, 2024
Merged

Add unstable --dep-coverage option #353

merged 1 commit into from
Mar 10, 2024

Conversation

taiki-e
Copy link
Owner

@taiki-e taiki-e commented Mar 10, 2024

By default, cargo-llvm-cov only shows coverage of crates in the workspace.

This can be disabled by --disable-default-ignore-filename-regex flag. However, in this case, coverage of crates and all dependencies in the workspace will be shown.
disable-default-ignore-filename-regex

If you specify a dependency with the --dep-coverage option that this PR adds, only the coverage of that dependency will be shown. The following is using --dep-coverage memchr:
dep-coverage

The option is currently marked as unstable due to limitations such as not yet being able to show coverage other than dependencies from crates.io.

cc @xizheyin

@xizheyin
Copy link

Thank you very much! I was going to use a script for this, but I didn't expect to implement this feature so quickly!

@taiki-e taiki-e merged commit 541f698 into main Mar 10, 2024
18 checks passed
@taiki-e taiki-e deleted the dep-coverage branch March 10, 2024 09:29
@davidzeng0
Copy link

davidzeng0 commented Apr 4, 2024

there is a typo

        --dep-coverage <NAME>
            Show coverage of th specified dependency instead of the crates in the current workspace. (unstable)

taiki-e added a commit that referenced this pull request Apr 4, 2024
@taiki-e
Copy link
Owner Author

taiki-e commented Apr 4, 2024

@davidzeng0 Good catch! Fixed in 1490458.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants