[wip] cli capability parity
Some checks failed
CI / Rustfmt (push) Successful in 23s
CI / Cargo Audit & Deny (push) Successful in 30s
CI / Web Blocking Checks (push) Successful in 48s
CI / Security Blocking Checks (push) Successful in 8s
CI / Clippy (push) Failing after 1m55s
CI / Web Advisory Checks (push) Successful in 35s
CI / Security Advisory Checks (push) Successful in 37s
CI / Tests (push) Successful in 8m5s

This commit is contained in:
2026-03-06 16:58:50 -06:00
parent 48b6ca6bd7
commit 87d830f952
94 changed files with 3694 additions and 734 deletions

View File

@@ -20,6 +20,7 @@ use serde_json::json;
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule() {
let pool = create_test_pool().await.unwrap();
@@ -80,6 +81,7 @@ async fn test_create_rule() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule_disabled() {
let pool = create_test_pool().await.unwrap();
@@ -121,6 +123,7 @@ async fn test_create_rule_disabled() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule_with_complex_conditions() {
let pool = create_test_pool().await.unwrap();
@@ -170,6 +173,7 @@ async fn test_create_rule_with_complex_conditions() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule_duplicate_ref() {
let pool = create_test_pool().await.unwrap();
@@ -246,6 +250,7 @@ async fn test_create_rule_duplicate_ref() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule_invalid_ref_format_uppercase() {
let pool = create_test_pool().await.unwrap();
@@ -287,6 +292,7 @@ async fn test_create_rule_invalid_ref_format_uppercase() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_create_rule_invalid_ref_format_no_dot() {
let pool = create_test_pool().await.unwrap();
@@ -332,6 +338,7 @@ async fn test_create_rule_invalid_ref_format_no_dot() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rule_by_id() {
let pool = create_test_pool().await.unwrap();
@@ -380,6 +387,7 @@ async fn test_find_rule_by_id() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rule_by_id_not_found() {
let pool = create_test_pool().await.unwrap();
@@ -389,6 +397,7 @@ async fn test_find_rule_by_id_not_found() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rule_by_ref() {
let pool = create_test_pool().await.unwrap();
@@ -437,6 +446,7 @@ async fn test_find_rule_by_ref() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rule_by_ref_not_found() {
let pool = create_test_pool().await.unwrap();
@@ -448,6 +458,7 @@ async fn test_find_rule_by_ref_not_found() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_list_rules() {
let pool = create_test_pool().await.unwrap();
@@ -500,6 +511,7 @@ async fn test_list_rules() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_list_rules_ordered_by_ref() {
let pool = create_test_pool().await.unwrap();
@@ -558,6 +570,7 @@ async fn test_list_rules_ordered_by_ref() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_label() {
let pool = create_test_pool().await.unwrap();
@@ -610,6 +623,7 @@ async fn test_update_rule_label() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_description() {
let pool = create_test_pool().await.unwrap();
@@ -660,6 +674,7 @@ async fn test_update_rule_description() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_conditions() {
let pool = create_test_pool().await.unwrap();
@@ -711,6 +726,7 @@ async fn test_update_rule_conditions() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_enabled() {
let pool = create_test_pool().await.unwrap();
@@ -763,6 +779,7 @@ async fn test_update_rule_enabled() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_multiple_fields() {
let pool = create_test_pool().await.unwrap();
@@ -820,6 +837,7 @@ async fn test_update_rule_multiple_fields() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_update_rule_no_changes() {
let pool = create_test_pool().await.unwrap();
@@ -872,6 +890,7 @@ async fn test_update_rule_no_changes() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_delete_rule() {
let pool = create_test_pool().await.unwrap();
@@ -919,6 +938,7 @@ async fn test_delete_rule() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_delete_rule_not_found() {
let pool = create_test_pool().await.unwrap();
@@ -932,6 +952,7 @@ async fn test_delete_rule_not_found() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rules_by_pack() {
let pool = create_test_pool().await.unwrap();
@@ -1021,6 +1042,7 @@ async fn test_find_rules_by_pack() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rules_by_action() {
let pool = create_test_pool().await.unwrap();
@@ -1102,6 +1124,7 @@ async fn test_find_rules_by_action() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_rules_by_trigger() {
let pool = create_test_pool().await.unwrap();
@@ -1185,6 +1208,7 @@ async fn test_find_rules_by_trigger() {
}
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_find_enabled_rules() {
let pool = create_test_pool().await.unwrap();
@@ -1264,6 +1288,7 @@ async fn test_find_enabled_rules() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_cascade_delete_pack_deletes_rules() {
let pool = create_test_pool().await.unwrap();
@@ -1319,6 +1344,7 @@ async fn test_cascade_delete_pack_deletes_rules() {
// ============================================================================
#[tokio::test]
#[ignore = "integration test — requires database"]
async fn test_rule_timestamps() {
let pool = create_test_pool().await.unwrap();