summaryrefslogtreecommitdiff
path: root/rust/kernel/init.rs
diff options
context:
space:
mode:
authorBenno Lossin <lossin@kernel.org>2025-06-05 17:52:54 +0200
committerBenno Lossin <lossin@kernel.org>2025-06-11 21:13:57 +0200
commitfc3870dc5cadb701b4122e4a8daa85f9fa2f57b9 (patch)
tree68826d300e855630fa4dc4fcc5b212ae7160401b /rust/kernel/init.rs
parentf744a5b68eead2cc73691e91182522c7d800245e (diff)
rust: pin-init: examples, tests: use `ignore` instead of conditionally compiling tests
Change `#[cfg(cond)]` to `#[cfg_attr(not(cond), ignore)]` on tests. Ignoring tests instead of disabling them still makes them appear in the test list, but with `ignored`. It also still compiles the code in those cases. Some tests still need to be ignore, because they use types that are not present when the condition is false. For example the condition is `feature = std` and then it uses `std::thread::Thread`. Suggested-by: Alice Ryhl <aliceryhl@google.com> Link: https://lore.kernel.org/all/aDC9y829vZZBzZ2p@google.com Link: https://github.com/Rust-for-Linux/pin-init/pull/58/commits/b004dd8e64d4cbe219a4eff0d25f0a5f5bc750ca Reviewed-by: Christian Schrefl <chrisi.schrefl@gmail.com> Link: https://lore.kernel.org/all/20250605155258.573391-1-lossin@kernel.org Signed-off-by: Benno Lossin <lossin@kernel.org>
Diffstat (limited to 'rust/kernel/init.rs')
0 files changed, 0 insertions, 0 deletions