test(web): adapt ui-trajectory benches to the merged locale settings scope

The locale plugin now derives its durable preference from a settings scope
bound to the connection service, so the trajectory benches provide a
connection handle before loading it.
This commit is contained in:
_Kerman
2026-08-10 20:15:31 +08:00
parent 9b96a1380b
commit fa2dce28ce
2 changed files with 6 additions and 2 deletions

View File

@@ -181,7 +181,9 @@ async function bench(snapshot = historySnapshot(NODES)) {
slots.register(
{ name: 'conversation.view', id: 'chat', order: 0, label: 'Chat' } as never, chatBody as never)
ctx.provide('sessionHistory', { source: () => history })
// The locale plugin backs the locale-aware view tab label ('locale' in inject).
// The locale plugin backs the locale-aware view tab label ('locale' in
// inject); its settings scope needs a connection handle.
ctx.provide('connection', { api: { settings: {} }, isLoopback: false } as never)
ctx.plugin({ inject: [...localeInject], apply: localeApply })
const fiber = ctx.plugin({ inject: [...inject], apply })
await fiber.await()