godmode-core 0.8.1

Core library for godmode: task graphs, session state, dispatch, and Claude Code plugin integrations.
Documentation
1
2
3
4
5
6
7
8
9
10
11
//! testing-philosophy — PreToolUse/Write hook.
//! Warns if a src/ file has no associated tests.

use std::path::Path;

use crate::test_check;

/// Run the testing-philosophy hook. Returns a message for stderr (may be empty).
pub fn run(root: &Path, file_path: &str) -> String {
    test_check::check_test_coverage(file_path, root).unwrap_or_default()
}