mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:31:09 +00:00
Trim Guardian tests and tighten request layout assertions (#46063)
## What changed Remove standalone tests across Guardian review sessions, configuration, assessment schemas, transcripts, and trusted skill paths. Strengthen the existing request layout snapshot test to check exact transcript separators, the action header, and parent session ID placement before snapshot whitespace normalization. Concatenate user input text without inserting newlines so the assertions validate the actual request formatting. GitOrigin-RevId: 06d262a1a85b1a8401796958f300c894146d2e1b
This commit is contained in:
1 parent
8ace915ace
commit
e412b93d08
5 files changed
+5
-370
No files matched your search
@@ -50,34 +50,3 @@ fn parse_guardian_assessment_treats_bare_deny_as_high_risk() {
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn guardian_output_schema_requires_only_outcome_and_allows_optional_details() {
|
||||
let schema = guardian_output_schema();
|
||||
|
||||
assert_eq!(
|
||||
schema,
|
||||
serde_json::json!({
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"risk_level": {
|
||||
"type": "string",
|
||||
"enum": ["low", "medium", "high", "critical"]
|
||||
},
|
||||
"user_authorization": {
|
||||
"type": "string",
|
||||
"enum": ["unknown", "low", "medium", "high"]
|
||||
},
|
||||
"outcome": {
|
||||
"type": "string",
|
||||
"enum": ["allow", "deny"]
|
||||
},
|
||||
"rationale": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["outcome"]
|
||||
})
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user