test(gate): expect uniform tool-result frame in compressed-context assertion
The tool-output framing feature (2912799f) wraps every tool result in a
'[tool exit=N]' header before it enters context. Compression still runs
(blank lines stripped); the test predated the frame and asserted the bare
compressed body. Update to the framed contract — invariant #6 unchanged.
This commit is contained in:
@@ -377,11 +377,12 @@ class ToolCallGateTest {
|
||||
orchestrator.run(SessionId("compress"), singleStageGraph(), config)
|
||||
|
||||
// The second inference carries round-1's tool result in its context pack — compressed
|
||||
// (blank lines stripped), not raw. Raw output stays authoritative on the executor's
|
||||
// event path (invariant #6); the compressor only shapes the derived context entry.
|
||||
// (blank lines stripped), not raw, under the uniform `[tool exit=N]` frame the model sees.
|
||||
// Raw output stays authoritative on the executor's event path (invariant #6); the compressor
|
||||
// only shapes the derived context entry.
|
||||
val secondPack = provider.requests[1].contextPack
|
||||
val toolEntry = secondPack.layers.values.flatten().first { it.sourceType == "toolResult" }
|
||||
assertEquals("line1\nline2\nline3", toolEntry.content)
|
||||
assertEquals("[file_write exit=0]\nline1\nline2\nline3", toolEntry.content)
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user