Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions integration-tests/cli/acp-integration.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -508,17 +508,17 @@ function setupAcpTest(
expect(modelOption).toBeDefined();
expect(modelOption!.currentValue).toBeTruthy();

const modelId = modelOption!.currentValue;
expect(
newSession.models.availableModels.some(
(model) => model.modelId === modelId,
),
).toBe(true);
// Test: Set model using set_config_option
// Use openai model to avoid auth issues
const openaiModel = newSession.models.availableModels.find((model) =>
model.modelId.includes('openai'),
);
expect(openaiModel).toBeDefined();

const setModelResult = (await sendRequest('session/set_config_option', {
sessionId: newSession.sessionId,
configId: 'model',
value: modelId,
value: openaiModel!.modelId,
})) as {
configOptions: Array<{
id: string;
Expand All @@ -535,7 +535,7 @@ function setupAcpTest(
(opt) => opt.id === 'model',
);
expect(updatedModelOption).toBeDefined();
expect(updatedModelOption!.currentValue).toBe(modelId);
expect(updatedModelOption!.currentValue).toBe(openaiModel!.modelId);
} catch (e) {
if (stderr.length) {
console.error('Agent stderr:', stderr.join(''));
Expand Down
Loading