From 55374453e7d1f55100a81c497aa42e13c6ea9767 Mon Sep 17 00:00:00 2001 From: Stanislav Tkach Date: Thu, 12 Dec 2024 11:55:17 +0100 Subject: [PATCH] Update Clippy and rustfmt configs --- rust/Earthfile | 2 +- rust/clippy.toml | 1 + rust/rbac-registration/src/cardano/cip509/utils/cip134.rs | 2 +- rust/rustfmt.toml | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/rust/Earthfile b/rust/Earthfile index 2afaf65c99..04ec97997f 100644 --- a/rust/Earthfile +++ b/rust/Earthfile @@ -1,6 +1,6 @@ VERSION 0.8 -IMPORT github.com/input-output-hk/catalyst-ci/earthly/rust:v3.2.23 AS rust-ci +IMPORT github.com/input-output-hk/catalyst-ci/earthly/rust:v3.2.25 AS rust-ci COPY_SRC: FUNCTION diff --git a/rust/clippy.toml b/rust/clippy.toml index 0358cdb508..7bada5473b 100644 --- a/rust/clippy.toml +++ b/rust/clippy.toml @@ -1,2 +1,3 @@ allow-unwrap-in-tests = true allow-expect-in-tests = true +allow-panic-in-tests = true diff --git a/rust/rbac-registration/src/cardano/cip509/utils/cip134.rs b/rust/rbac-registration/src/cardano/cip509/utils/cip134.rs index 73f5d26a9a..d4be9cd883 100644 --- a/rust/rbac-registration/src/cardano/cip509/utils/cip134.rs +++ b/rust/rbac-registration/src/cardano/cip509/utils/cip134.rs @@ -107,7 +107,7 @@ mod tests { for uri in test_uris { let err = format!("{:?}", Cip0134Uri::parse(uri).expect_err(uri)); - assert_eq!("Missing schema part of URI", err); + assert!(err.starts_with("Missing schema part of URI")); } } diff --git a/rust/rustfmt.toml b/rust/rustfmt.toml index b0f20832c9..905bde2d0b 100644 --- a/rust/rustfmt.toml +++ b/rust/rustfmt.toml @@ -36,7 +36,7 @@ max_width = 100 # Comments: normalize_comments = true -normalize_doc_attributes = true +normalize_doc_attributes = false wrap_comments = true comment_width = 90 # small excess is okay but prefer 80 format_code_in_doc_comments = true