MCPcopy Create free account
hub / github.com/PerroEngine/Perro / collect_source_api_names_dir

Function collect_source_api_names_dir

perro_website/src/docs.rs:402–421  ·  view source on GitHub ↗
(dir: &Path, names: &mut BTreeSet<String>)

Source from the content-addressed store, hash-verified

400
401 #[test]
402 fn docs_do_not_use_generic_api_placeholder_prose() {
403 let banned = [
404 "Use when this exact typed operation matches the system state the script needs to read or change.",
405 "Option returns None for missing data",
406 "ID-based calls fail when the ID is stale",
407 ];
408
409 let mut failures = Vec::new();
410 for doc in docs() {
411 if doc.collection != "docs" {
412 continue;
413 }
414 for needle in banned {
415 if doc.markdown.contains(needle) {
416 failures.push(format!("{} contains placeholder prose", doc.slug));
417 }
418 }
419 }
420
421 assert!(failures.is_empty(), "{}", failures.join("\n"));
422 }
423
424 #[test]

Callers 1

collect_source_api_namesFunction · 0.85

Calls 3

read_dirFunction · 0.85
pathMethod · 0.45

Tested by

no test coverage detected