Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/audit-guard/src/drift_validator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ impl DriftEvent {
}

// Use chrono for timestamp parsing – it is already a dependency in the workspace.
use chrono::{DateTime, FixedOffset};
use chrono::DateTime;

/// Configurable threshold for drift validation.
/// In a real implementation this would be loaded from a policy file (e.g., OPA),
Expand All @@ -52,3 +52,10 @@ pub fn validate_drift(event: &DriftEvent) -> Result<(), DriftError> {
// For now we assume the static threshold is sufficient.
Ok(())
}

// Wire the previously-unreferenced drift validator tests into the crate so that
// `cargo test` actually compiles and runs them. They live in
// `drift_validator_test.rs` and use `super::*` (this module's scope already
// brings `DriftEvent`, `validate_drift`, and `DriftError` into view).
#[cfg(test)]
mod drift_validator_test;
Loading