Optional features are part of the crate — the project should say so
Rust Internals [Unofficial]
March 13, 2026
Yes, I have multiple sets of jobs for such cases. Each job set uses a CARGO_FEATURES to set the flags to use for each, so I expect build and test to behave similarly for the same set of flags.
Discussion in the ATmosphere