mirror of
https://github.com/openai/codex.git
synced 2026-11-14 21:40:39 +00:00
Test exec catalog preservation across session and compaction changes (#60173)
## What changed - Cover incremental exec tool settings and catalog changes across resume, fork, tool mode switches, and compaction. - Verify that adopting background compaction preserves live exec declarations, tool metadata updates, and retained conversation order after a model catalog refresh. - Include an `exec` namespace in the top-level tool catalog ordering and snapshot round-trip test. GitOrigin-RevId: 3df603b98a006abb55a5095b299080f036576242
This commit is contained in:
@@ -267,6 +267,7 @@ fn initial_catalog_preserves_order_and_unchanged_catalog_emits_nothing() {
|
||||
let definitions = vec![
|
||||
namespace("zebra", vec![declaration("lookup")]),
|
||||
namespace("alpha", vec![declaration("lookup")]),
|
||||
namespace("exec", vec![declaration("lookup")]),
|
||||
];
|
||||
let state = TopLevelToolsState::new(
|
||||
/*messages*/ Default::default(),
|
||||
@@ -293,7 +294,14 @@ fn initial_catalog_preserves_order_and_unchanged_catalog_emits_nothing() {
|
||||
.keys()
|
||||
.map(String::as_str)
|
||||
.collect::<Vec<_>>(),
|
||||
vec!["alpha", "alpha.lookup", "zebra", "zebra.lookup"]
|
||||
vec![
|
||||
"alpha",
|
||||
"alpha.lookup",
|
||||
"exec",
|
||||
"exec.lookup",
|
||||
"zebra",
|
||||
"zebra.lookup"
|
||||
]
|
||||
);
|
||||
let snapshot: TopLevelToolsSnapshot = serde_json::from_value(saved).unwrap();
|
||||
let (unchanged_snapshot, updates) = state.render_diff(PreviousSectionState::Known(&snapshot));
|
||||
|
||||
Reference in New Issue
Block a user