ferrous_forge/safety/checks/
doc.rs1use crate::Result;
4use std::path::Path;
5use std::time::Instant;
6
7use super::SafetyCheck;
8use crate::safety::{report::CheckResult, CheckType};
9
10pub struct DocCheck;
12
13impl SafetyCheck for DocCheck {
14 async fn run(project_path: &Path) -> Result<CheckResult> {
15 run(project_path).await
16 }
17
18 fn name() -> &'static str {
19 "doc"
20 }
21
22 fn description() -> &'static str {
23 "Builds project documentation"
24 }
25}
26
27pub async fn run(project_path: &Path) -> Result<CheckResult> {
29 let start = Instant::now();
30 let mut result = CheckResult::new(CheckType::Doc);
31 result.set_duration(start.elapsed());
32 result.add_context(&format!(
33 "Documentation check placeholder for {} - always passes",
34 project_path.display()
35 ));
36 Ok(result)
37}
38
39pub async fn coverage_check(project_path: &Path) -> Result<CheckResult> {
41 let start = Instant::now();
42 let mut result = CheckResult::new(CheckType::DocCoverage);
43 result.set_duration(start.elapsed());
44 result.add_context(&format!(
45 "Documentation coverage check placeholder for {} - always passes",
46 project_path.display()
47 ));
48 Ok(result)
49}