mirror of
https://github.com/tauri-apps/tauri.git
synced 2026-04-01 10:01:07 +02:00
chore(lint): fix warnings
This commit is contained in:
@@ -813,9 +813,7 @@ mod tests {
|
||||
fn get_manifest() -> &'static Manifest {
|
||||
MANIFEST.get_or_init(|| {
|
||||
let manifest_dir = PathBuf::from(var("CARGO_MANIFEST_DIR").unwrap());
|
||||
let manifest = Manifest::from_path(manifest_dir.join("Cargo.toml"))
|
||||
.expect("failed to parse Cargo manifest");
|
||||
manifest
|
||||
Manifest::from_path(manifest_dir.join("Cargo.toml")).expect("failed to parse Cargo manifest")
|
||||
})
|
||||
}
|
||||
|
||||
@@ -824,7 +822,7 @@ mod tests {
|
||||
let manifest_dir = PathBuf::from(var("CARGO_MANIFEST_DIR").unwrap());
|
||||
let lib_code = read_to_string(manifest_dir.join("src/lib.rs")).expect("failed to read lib.rs");
|
||||
|
||||
for (f, _) in &get_manifest().features {
|
||||
for f in get_manifest().features.keys() {
|
||||
if !(f.starts_with("__") || f == "default" || lib_code.contains(&format!("*{}**", f))) {
|
||||
panic!("Feature {} is not documented", f);
|
||||
}
|
||||
|
||||
@@ -1390,6 +1390,7 @@ mod tests {
|
||||
#[test]
|
||||
fn string_replace_with_callback() {
|
||||
let mut tauri_index = 0;
|
||||
#[allow(clippy::single_element_loop)]
|
||||
for (src, pattern, replacement, result) in [(
|
||||
"tauri is awesome, tauri is amazing",
|
||||
"tauri",
|
||||
|
||||
Reference in New Issue
Block a user