4 ms·
dead_code is required because Rust compiles each integration test as a separate crate. This causes spurious warnings to be emitted if you want to share code bet
by ridiculous_fish 4y ago
dead_code is required because Rust compiles each integration test as a separate crate. This causes spurious warnings to be emitted if you want to share code between tests. See https://github.com/rust-lang/rust/issues/46379 https://github.com/rust-lang/rust/issues/46379
Modules and crates continues to be one of the most confusing aspects of Rust, for me at least.
- masklinn 4y agoHere dead code is on the SUT not on the test utilities. In that situation the SUT would normally be either used or pub, here it’s not because the SUT is artificial, library-type code in a binary crate.