MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / validate_rejects_empty_run_as_user

Function validate_rejects_empty_run_as_user

crates/openshell-policy/src/lib.rs:1761–1769  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1759
1760 #[test]
1761 fn validate_rejects_empty_run_as_user() {
1762 let mut policy = restrictive_default_policy();
1763 policy.process = Some(ProcessPolicy {
1764 run_as_user: String::new(),
1765 run_as_group: String::new(),
1766 });
1767 let violations = validate_sandbox_policy(&policy).unwrap_err();
1768 assert_eq!(violations.len(), 2);
1769 }
1770
1771 #[test]
1772 fn validate_rejects_too_many_paths() {

Callers

nothing calls this directly

Calls 2

validate_sandbox_policyFunction · 0.85

Tested by

no test coverage detected