Skip to content

Commit b1d14c1

Browse files
committed
Update clippy lints
1 parent cbbcf29 commit b1d14c1

File tree

2 files changed

+23
-6
lines changed

2 files changed

+23
-6
lines changed

src/lib.rs

+21-4
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,36 @@
1-
// BEGIN - Embark standard lints v0.3
1+
// BEGIN - Embark standard lints v0.4
22
// do not change or add/remove here, but one can add exceptions after this section
33
// for more info see: <https://github.com/EmbarkStudios/rust-ecosystem/issues/59>
44
#![deny(unsafe_code)]
55
#![warn(
66
clippy::all,
77
clippy::await_holding_lock,
8+
clippy::char_lit_as_u8,
9+
clippy::checked_conversions,
810
clippy::dbg_macro,
911
clippy::debug_assert_with_mut_call,
1012
clippy::doc_markdown,
1113
clippy::empty_enum,
1214
clippy::enum_glob_use,
1315
clippy::exit,
16+
clippy::expl_impl_clone_on_copy,
17+
clippy::explicit_deref_methods,
1418
clippy::explicit_into_iter_loop,
19+
clippy::fallible_impl_from,
1520
clippy::filter_map_next,
21+
clippy::float_cmp_const,
1622
clippy::fn_params_excessive_bools,
1723
clippy::if_let_mutex,
24+
clippy::implicit_clone,
1825
clippy::imprecise_flops,
1926
clippy::inefficient_to_string,
27+
clippy::invalid_upcast_comparisons,
2028
clippy::large_types_passed_by_value,
2129
clippy::let_unit_value,
2230
clippy::linkedlist,
2331
clippy::lossy_float_literal,
2432
clippy::macro_use_imports,
33+
clippy::manual_ok_or,
2534
clippy::map_err_ignore,
2635
clippy::map_flatten,
2736
clippy::map_unwrap_or,
@@ -30,26 +39,34 @@
3039
clippy::match_wildcard_for_single_variants,
3140
clippy::mem_forget,
3241
clippy::mismatched_target_os,
42+
clippy::mut_mut,
43+
clippy::mutex_integer,
3344
clippy::needless_borrow,
3445
clippy::needless_continue,
3546
clippy::option_option,
36-
clippy::pub_enum_variant_names,
47+
clippy::path_buf_push_overwrite,
48+
clippy::ptr_as_ptr,
3749
clippy::ref_option_ref,
3850
clippy::rest_pat_in_fully_bound_structs,
51+
clippy::same_functions_in_if_condition,
52+
clippy::semicolon_if_nothing_returned,
3953
clippy::string_add_assign,
4054
clippy::string_add,
55+
clippy::string_lit_as_bytes,
4156
clippy::string_to_string,
42-
clippy::suboptimal_flops,
4357
clippy::todo,
58+
clippy::trait_duplication_in_bounds,
4459
clippy::unimplemented,
4560
clippy::unnested_or_patterns,
4661
clippy::unused_self,
62+
clippy::useless_transmute,
4763
clippy::verbose_file_reads,
64+
clippy::zero_sized_map_values,
4865
future_incompatible,
4966
nonstandard_style,
5067
rust_2018_idioms
5168
)]
52-
// END - Embark standard lints v0.3
69+
// END - Embark standard lints v0.4
5370

5471
#[macro_use(Deserialize, Serialize)]
5572
extern crate serde;

tests/objects.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,7 @@ fn deserializes_partial_rewrite_response() {
552552
objects::RewriteObjectResponse::try_from(response).expect("parsed rewrite response");
553553

554554
assert_eq!(rewrite_response.total_bytes_rewritten, 435);
555-
assert_eq!(rewrite_response.done, false);
555+
assert!(!rewrite_response.done);
556556
assert_eq!(rewrite_response.rewrite_token.unwrap(), "tokendata");
557557
}
558558

@@ -591,7 +591,7 @@ fn deserializes_complete_rewrite_response() {
591591
objects::RewriteObjectResponse::try_from(response).expect("parsed rewrite response");
592592

593593
assert_eq!(rewrite_response.total_bytes_rewritten, 435);
594-
assert_eq!(rewrite_response.done, true);
594+
assert!(rewrite_response.done);
595595
assert_eq!(
596596
rewrite_response.metadata.unwrap().name.unwrap(),
597597
"script.sh"

0 commit comments

Comments
 (0)