mirror of https://github.com/helix-editor/helix
Compare commits
3 Commits
c142d85f71
...
c86b415965
Author | SHA1 | Date |
---|---|---|
|
c86b415965 | |
|
b40aba78e4 | |
|
623e5de848 |
|
@ -115,6 +115,7 @@ fn find_coverage_file() -> Option<std::path::PathBuf> {
|
||||||
return Some(std::path::PathBuf::from(coverage_path));
|
return Some(std::path::PathBuf::from(coverage_path));
|
||||||
}
|
}
|
||||||
for entry in walkdir::WalkDir::new(".")
|
for entry in walkdir::WalkDir::new(".")
|
||||||
|
.max_depth(1)
|
||||||
.into_iter()
|
.into_iter()
|
||||||
.filter_map(|e| e.ok())
|
.filter_map(|e| e.ok())
|
||||||
{
|
{
|
||||||
|
@ -161,7 +162,7 @@ impl From<RawCoverage> for Coverage {
|
||||||
// so check each in the path
|
// so check each in the path
|
||||||
let raw_path: std::path::PathBuf =
|
let raw_path: std::path::PathBuf =
|
||||||
[&source.name, &class.filename].iter().collect();
|
[&source.name, &class.filename].iter().collect();
|
||||||
if let Ok(path) = std::fs::canonicalize(raw_path) {
|
if let Ok(path) = std::fs::canonicalize(raw_path.clone()) {
|
||||||
log::debug!("add file {:?} to coverage", path);
|
log::debug!("add file {:?} to coverage", path);
|
||||||
files.insert(
|
files.insert(
|
||||||
path,
|
path,
|
||||||
|
@ -172,7 +173,7 @@ impl From<RawCoverage> for Coverage {
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
log::warn!("could not add file {:?} to coverage", path);
|
log::warn!("could not add file {:?} to coverage", raw_path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -172,7 +172,7 @@ pub fn coverage<'doc>(
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
log::info!("return empty coverage gutter for {:?}", document_path);
|
log::info!("return empty coverage gutter");
|
||||||
return Box::new(move |_, _, _, _| None);
|
return Box::new(move |_, _, _, _| None);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue