Skip to content
Myr

Ignore assertions_on_result_states clippy lint

Before adoption: this commit came in with the history the project adopted, so no landing records it.

error: called `assert!` with `Result::is_ok` --> tests/test_macros.rs:29:5 | 29 | assert!(f().is_ok()); | ^^^^^^^^^^^^^^^^^^^^ help: replace with: `f().unwrap()` | = note: `-D clippy::assertions-on-result-states` implied by `-D clippy::all` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_result_states error: called `assert!` with `Result::is_ok` --> tests/test_macros.rs:36:5 | 36 | assert!(f().is_ok()); | ^^^^^^^^^^^^^^^^^^^^ help: replace with: `f().unwrap()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_result_states error: called `assert!` with `Result::is_err` --> tests/test_macros.rs:42:5 | 42 | assert!(f().is_err()); | ^^^^^^^^^^^^^^^^^^^^^ help: replace with: `f().unwrap_err()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_result_states error: called `assert!` with `Result::is_err` --> tests/test_downcast.rs:122:5 | 122 | assert!(error.downcast::<&str>().is_err()); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `error.downcast::<&str>().unwrap_err()` | = note: `-D clippy::assertions-on-result-states` implied by `-D clippy::all` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_result_states

authored by David Tolnay · committed by David Tolnay · parent b594668 · Browse files · 2 files+2 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+2 added−1 removed

  • tests:+2 added−1 removed

2 files+2 added−1 removed

modified:tests/test_downcast.rs+1 added-1 removed
1#![allow(clippy::wildcard_imports)]1#![allow(clippy::assertions_on_result_states, clippy::wildcard_imports)]23mod common;4mod drop;5
118 unmodified lines
modified:tests/test_macros.rs+1 added
1#![allow(2 clippy::assertions_on_result_states,3 clippy::eq_op,4 clippy::items_after_statements,5 clippy::needless_pass_by_value,6 clippy::shadow_unrelated,
74 unmodified lines