aboutsummaryrefslogtreecommitdiffstats
path: root/tests/readme.rs
diff options
context:
space:
mode:
authorSven-Hendrik Haase <svenstaro@gmail.com>2022-12-19 11:49:59 +0000
committerSven-Hendrik Haase <svenstaro@gmail.com>2022-12-19 11:49:59 +0000
commit646742fdeac25f2b92b7295f2e6250adaf7f5c53 (patch)
tree6788656eef9f0b9049ad6d90bbb8cb72296412c7 /tests/readme.rs
parentBump deps (diff)
downloadminiserve-646742fdeac25f2b92b7295f2e6250adaf7f5c53.tar.gz
miniserve-646742fdeac25f2b92b7295f2e6250adaf7f5c53.zip
Fix lints
Diffstat (limited to '')
-rw-r--r--tests/readme.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/readme.rs b/tests/readme.rs
index 3fcbe29..2a0ad13 100644
--- a/tests/readme.rs
+++ b/tests/readme.rs
@@ -52,7 +52,7 @@ fn show_root_readme_contents(
assert!(parsed.find(|x: &Node| x.text() == file).next().is_some());
}
// ...in addition to the readme contents below the file listing.
- assert_readme_contents(&parsed, &readme_name);
+ assert_readme_contents(&parsed, readme_name);
remove_file(readme_path).unwrap();
Ok(())
}
@@ -84,7 +84,7 @@ fn show_nested_readme_contents(
assert!(parsed.find(|x: &Node| x.text() == file).next().is_some());
}
// ...in addition to the readme contents below the file listing.
- assert_readme_contents(&parsed, &readme_name);
+ assert_readme_contents(&parsed, readme_name);
remove_file(readme_path).unwrap();
}
Ok(())
@@ -94,7 +94,7 @@ fn write_readme_contents(path: PathBuf, filename: &str) -> PathBuf {
let readme_path = path.join(filename);
let mut readme_file = File::create(&readme_path).unwrap();
readme_file
- .write(format!("Contents of {}", filename).to_string().as_bytes())
+ .write(format!("Contents of {filename}").as_bytes())
.expect("Couldn't write readme");
readme_path
}
@@ -123,5 +123,5 @@ fn assert_readme_contents(parsed_dom: &Document, filename: &str) {
.unwrap()
.text()
.trim()
- .contains(&format!("Contents of {}", filename)));
+ .contains(&format!("Contents of {filename}")));
}