diff --git a/tests/ui/unknown_clippy_lints.rs b/tests/ui/unknown_clippy_lints.rs new file mode 100644 index 000000000000..0ea20092246e --- /dev/null +++ b/tests/ui/unknown_clippy_lints.rs @@ -0,0 +1,8 @@ + +#![allow(clippy::All)] +#![warn(clippy::pedantic)] + +#[warn(clippy::if_not_els)] +fn main() { + +} diff --git a/tests/ui/unknown_clippy_lints.stderr b/tests/ui/unknown_clippy_lints.stderr new file mode 100644 index 000000000000..da1234e77d07 --- /dev/null +++ b/tests/ui/unknown_clippy_lints.stderr @@ -0,0 +1,16 @@ +error: unknwon clippy lint: clippy::if_not_els + --> $DIR/unknown_clippy_lints.rs:5:8 + | +5 | #[warn(clippy::if_not_els)] + | ^^^^^^^^^^^^^^^^^^ + | + = note: `-D clippy::unknown-clippy-lints` implied by `-D warnings` + +error: unknwon clippy lint: clippy::All + --> $DIR/unknown_clippy_lints.rs:2:10 + | +2 | #![allow(clippy::All)] + | ^^^^^^^^^^^ help: lowercase the lint name: `all` + +error: aborting due to 2 previous errors +