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

Fix feature tests #12

Merged
merged 3 commits into from
Oct 31, 2023
Merged

Fix feature tests #12

merged 3 commits into from
Oct 31, 2023

Conversation

kylewillmon
Copy link
Contributor

@kylewillmon kylewillmon commented Oct 31, 2023

Fixes #10

See related issue and individual commit messages for details.

@kylewillmon kylewillmon self-assigned this Oct 31, 2023
@kylewillmon kylewillmon marked this pull request as ready for review October 31, 2023 17:38
Using `--no-default-features` on the workspace does not work as expected
because the `purl_test` and `xtask` crates depend on certain features of
the `purl` crate. So with feature unification, the `purl` crate is built
with those features **enabled**.

To resolve this and simplify the tests, this patch switches the default
and minimal tests to only test the `purl` crate itself. The "Full" test
is left to test the entire workspace with code coverage.

This technically leaves open the possibility that `purl_test` or `xtask`
may not successfully build with default features... But since those are
test and development crates, I'm not actually concerned.
`PackageType` is only available with the `package-type` feature. So it's
best to avoid it in unrelated doctests. Otherwise, they will fail when
run without default features.
@matt-phylum matt-phylum merged commit fde807c into main Oct 31, 2023
6 checks passed
@matt-phylum matt-phylum deleted the feature-tests branch October 31, 2023 20:54
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.

Fails to build with default-features = false
2 participants