Skip to content

Commit 8d516b3

Browse files
committed
Add tests for unknwon_clippy_lints lint
1 parent f6d5786 commit 8d516b3

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

tests/ui/unknown_clippy_lints.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
2+
#![allow(clippy::All)]
3+
#![warn(clippy::pedantic)]
4+
5+
#[warn(clippy::if_not_els)]
6+
fn main() {
7+
8+
}

tests/ui/unknown_clippy_lints.stderr

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
error: unknwon clippy lint: clippy::if_not_els
2+
--> $DIR/unknown_clippy_lints.rs:5:8
3+
|
4+
5 | #[warn(clippy::if_not_els)]
5+
| ^^^^^^^^^^^^^^^^^^
6+
|
7+
= note: `-D clippy::unknown-clippy-lints` implied by `-D warnings`
8+
9+
error: unknwon clippy lint: clippy::All
10+
--> $DIR/unknown_clippy_lints.rs:2:10
11+
|
12+
2 | #![allow(clippy::All)]
13+
| ^^^^^^^^^^^ help: lowercase the lint name: `all`
14+
15+
error: aborting due to 2 previous errors
16+

0 commit comments

Comments
 (0)