-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Description
Description
I've been struggling to make ignore_without_reason lint to work for my code, and it turned out that it won't work even for corresponding ui test from clippy repository:
#![warn(clippy::ignore_without_reason)]
fn main() {}
#[test]
fn unignored_test() {}
#[test]
#[ignore = "Some good reason"]
fn ignored_with_reason() {}
#[test]
#[ignore] //~ ignore_without_reason
fn ignored_without_reason() {}It took some time to discover that no lints work for test code at all, and then to discover undocumented --tests option by pure chance.
Is it expected that the option and the fact that it's required to lint tests is not documented or mentioned anywhere? IMO it is not right that https://rust-lang.github.io/rust-clippy/master/index.html#ignore_without_reason mention example which does not work.
Version
Additional Labels
No response
Metadata
Metadata
Assignees
Labels
No labels