From 700baa6fbcd1875adc63348c19a4858d1805f301 Mon Sep 17 00:00:00 2001 From: cyqsimon <28627918+cyqsimon@users.noreply.github.com> Date: Mon, 16 Sep 2024 21:50:50 +0800 Subject: [PATCH] Apply clippy lints --- tests/navigation.rs | 2 +- tests/rm_files.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/navigation.rs b/tests/navigation.rs index 115a5a859..ccbd35255 100644 --- a/tests/navigation.rs +++ b/tests/navigation.rs @@ -123,7 +123,7 @@ fn can_navigate_using_breadcrumbs( let dir = DEEPLY_NESTED_FILE.parent().unwrap().to_str().unwrap(); let base_url = server.url(); - let nested_url = base_url.join(&dir)?; + let nested_url = base_url.join(dir)?; let resp = reqwest::blocking::get(nested_url.as_str())?; let body = resp.error_for_status()?; diff --git a/tests/rm_files.rs b/tests/rm_files.rs index 78a1e8d61..884165585 100644 --- a/tests/rm_files.rs +++ b/tests/rm_files.rs @@ -51,7 +51,7 @@ fn make_del_path(unencoded_path: impl AsRef) -> String { fn assert_rm_ok(base_url: Url, unencoded_paths: &[impl AsRef]) -> anyhow::Result<()> { let client = Client::new(); - for file_path in unencoded_paths.into_iter().map(AsRef::as_ref) { + for file_path in unencoded_paths.iter().map(AsRef::as_ref) { // encode let get_url = base_url.join(&make_get_path(file_path))?; let del_url = base_url.join(&make_del_path(file_path))?; @@ -83,7 +83,7 @@ fn assert_rm_err( ) -> anyhow::Result<()> { let client = Client::new(); - for file_path in unencoded_paths.into_iter().map(AsRef::as_ref) { + for file_path in unencoded_paths.iter().map(AsRef::as_ref) { // encode let get_url = base_url.join(&make_get_path(file_path))?; let del_url = base_url.join(&make_del_path(file_path))?;