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

Idea: add flag to test all feature flag permutation w/ a max # of simultaneous feature flags #58

Closed
carllerche opened this issue Oct 10, 2020 · 1 comment · Fixed by #59
Assignees
Labels
A-features Area: features (--feature-powerset, --each-feature, etc.) C-enhancement Category: A new feature or an improvement for an existing one

Comments

@carllerche
Copy link

maybe --feature-powerset --depth 2.

Tokio has too many features to test the power set. However, most issues can be reproduced by testing at most 2 features simultaneously. It would be nice to have a feature that tested all permutations of at most N simultaneous feature flags. This would catch most problems.

@taiki-e taiki-e added the C-enhancement Category: A new feature or an improvement for an existing one label Oct 10, 2020
@taiki-e taiki-e self-assigned this Oct 10, 2020
@taiki-e taiki-e added the A-features Area: features (--feature-powerset, --each-feature, etc.) label Oct 10, 2020
@bors bors bot closed this as completed in #59 Oct 10, 2020
@bors bors bot closed this as completed in aff0e62 Oct 10, 2020
@taiki-e
Copy link
Owner

taiki-e commented Oct 10, 2020

Added in cargo-hack 0.3.14 (#59).

carllerche pushed a commit to tokio-rs/tokio that referenced this issue Sep 13, 2022
As has been pointed out a few times in the past (e.g., #4036 (comment)), each-feature 
is not sufficient for features check.

Ideally, we'd like to check all combinations of features, but there are too many
combinations. So limit the max number of simultaneous feature flags to 2 by --depth
option. I think this should be sufficient in most cases as @carllerche said in
taiki-e/cargo-hack#58.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-features Area: features (--feature-powerset, --each-feature, etc.) C-enhancement Category: A new feature or an improvement for an existing one
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants