From b4e659aa78ab5ae2afecfae62856b8b04d1d8dfc Mon Sep 17 00:00:00 2001 From: Marcus Haslam Date: Sat, 21 Oct 2023 00:31:49 +0100 Subject: [PATCH] 51: inline test var --- crates/fta/src/config/tests.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/crates/fta/src/config/tests.rs b/crates/fta/src/config/tests.rs index a6ef1d3..3f9d407 100644 --- a/crates/fta/src/config/tests.rs +++ b/crates/fta/src/config/tests.rs @@ -192,9 +192,7 @@ mod tests { #[test] fn temp_read_config_with_nonexistent_file_and_user_specified_file_path() { - let nonexistent_path = "nonexistent_file.json"; - - let config = read_config(nonexistent_path.to_string(), true); + let config = read_config(String::from("nonexistent_file.json"), true); assert!(config.is_err(), "Expected error, got {:?}", config); }