Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

test(doctor): assert ok flag in malformed config fallback cases

Steven Enamakeldb5bee0bf0e9
diff --git a/crates/openhuman-core/src/doctor/ops_tests.rs b/crates/openhuman-core/src/doctor/ops_tests.rs
index be2545c4cb..9587c3657e 100644
--- a/crates/openhuman-core/src/doctor/ops_tests.rs
+++ b/crates/openhuman-core/src/doctor/ops_tests.rs
@@ -34,6 +34,7 @@ async fn malformed_config_fallback_honors_exact_doctor_selectors() {
.value;
assert!(skipped.findings.is_empty());
assert!(skipped.checks_run.is_empty());
+ assert!(skipped.ok);
let selected_elsewhere = doctor_report_with_options(
&config,
@@ -47,6 +48,7 @@ async fn malformed_config_fallback_honors_exact_doctor_selectors() {
.value;
assert!(selected_elsewhere.findings.is_empty());
assert!(selected_elsewhere.checks_run.is_empty());
+ assert!(selected_elsewhere.ok);
let unknown = doctor_report_with_options(
&config,
@@ -60,6 +62,7 @@ async fn malformed_config_fallback_honors_exact_doctor_selectors() {
.value;
assert_eq!(unknown.findings.len(), 1);
assert_eq!(unknown.findings[0].check_id, "doctor/selection");
+ assert!(!unknown.ok);
let unfiltered = doctor_report_with_options(&config, DoctorOptions::default())
.await
@@ -67,6 +70,7 @@ async fn malformed_config_fallback_honors_exact_doctor_selectors() {
.value;
assert_eq!(unfiltered.findings.len(), 1);
assert_eq!(unfiltered.findings[0].check_id, "config/parse");
+ assert!(!unfiltered.ok);
}
#[tokio::test]