mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-29 11:42:17 +00:00
test(core): use native for text and reasoning provider blobs
This commit is contained in:
parent
347bf1d749
commit
e4dd41b033
2 changed files with 6 additions and 6 deletions
|
|
@ -564,7 +564,7 @@ export async function runNonInteractivePrompt(input: Input) {
|
|||
messageID: message.id,
|
||||
type: "reasoning",
|
||||
text,
|
||||
metadata: item.state,
|
||||
metadata: item.native,
|
||||
time: { start: message.time.created, end: timestamp },
|
||||
}
|
||||
renderedReasoning.set(key, item.text)
|
||||
|
|
|
|||
|
|
@ -3508,12 +3508,12 @@ describe("SessionRunnerLLM", () => {
|
|||
{
|
||||
type: "reasoning",
|
||||
text: "Signed thought",
|
||||
state: { signature: "sig_1" },
|
||||
native: { signature: "sig_1" },
|
||||
},
|
||||
{
|
||||
type: "reasoning",
|
||||
text: "Encrypted thought",
|
||||
state: { itemId: "rs_1", reasoningEncryptedContent: "encrypted-state" },
|
||||
native: { itemId: "rs_1", reasoningEncryptedContent: "encrypted-state" },
|
||||
},
|
||||
]),
|
||||
])
|
||||
|
|
@ -3565,7 +3565,7 @@ describe("SessionRunnerLLM", () => {
|
|||
{
|
||||
type: "reasoning",
|
||||
text: "thinking",
|
||||
state: { reasoningField: "reasoning", reasoningDetails: details },
|
||||
native: { reasoningField: "reasoning", reasoningDetails: details },
|
||||
},
|
||||
{ type: "text", text: "Hello world" },
|
||||
]),
|
||||
|
|
@ -3609,7 +3609,7 @@ describe("SessionRunnerLLM", () => {
|
|||
expect(yield* s.context).toMatchObject([
|
||||
Expected.user("Check first"),
|
||||
Expected.assistant({}, [
|
||||
{ type: "text", text: "Checking.", state: { itemId: "msg_commentary", phase: "commentary" } },
|
||||
{ type: "text", text: "Checking.", native: { itemId: "msg_commentary", phase: "commentary" } },
|
||||
]),
|
||||
])
|
||||
|
||||
|
|
@ -5444,7 +5444,7 @@ describe("SessionRunnerLLM", () => {
|
|||
{
|
||||
type: "reasoning",
|
||||
text: "",
|
||||
state: { itemId: "rs_disconnected", reasoningEncryptedContent: "encrypted-state" },
|
||||
native: { itemId: "rs_disconnected", reasoningEncryptedContent: "encrypted-state" },
|
||||
},
|
||||
]),
|
||||
{ type: "synthetic", text: INCOMPLETE_STREAM_CONTINUATION },
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue