Skip to content

Commit 309756f

Browse files
committed
Fix tests and build
1 parent 5d21285 commit 309756f

File tree

6 files changed

+17
-7
lines changed

6 files changed

+17
-7
lines changed

.agents/sessions/03-02-14:07-chatgpt-oauth-direct/LESSONS.md renamed to .agents/sessions/03-02-1407-chatgpt-oauth-direct/LESSONS.md

File renamed without changes.

.agents/sessions/03-02-14:07-chatgpt-oauth-direct/PLAN.md renamed to .agents/sessions/03-02-1407-chatgpt-oauth-direct/PLAN.md

File renamed without changes.

.agents/sessions/03-02-14:07-chatgpt-oauth-direct/SPEC.md renamed to .agents/sessions/03-02-1407-chatgpt-oauth-direct/SPEC.md

File renamed without changes.

cli/src/commands/__tests__/bash-command.test.ts

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -411,24 +411,25 @@ describe('bash command', () => {
411411
})
412412

413413
describe('bash mode configuration', () => {
414-
test('bash mode has correct icon', () => {
414+
test('bash mode has correct label', () => {
415415
const config = getInputModeConfig('bash')
416-
expect(config.icon).toBe('!')
416+
expect(config.icon).toBe(null)
417+
expect(config.label).toBe('!')
417418
})
418419

419-
test('bash mode uses success color (green)', () => {
420+
test('bash mode uses info color', () => {
420421
const config = getInputModeConfig('bash')
421-
expect(config.color).toBe('success')
422+
expect(config.color).toBe('info')
422423
})
423424

424425
test('bash mode has correct placeholder', () => {
425426
const config = getInputModeConfig('bash')
426427
expect(config.placeholder).toBe('enter bash command...')
427428
})
428429

429-
test('bash mode has width adjustment of 2', () => {
430+
test('bash mode has width adjustment of 4', () => {
430431
const config = getInputModeConfig('bash')
431-
expect(config.widthAdjustment).toBe(2)
432+
expect(config.widthAdjustment).toBe(4)
432433
})
433434

434435
test('bash mode hides agent mode toggle', () => {

web/src/llm-api/__tests__/fireworks-deployment.test.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ describe('Fireworks deployment routing', () => {
181181
originalModel: 'minimax/minimax-m2.5',
182182
fetch: mockFetch,
183183
logger,
184+
useCustomDeployment: true,
184185
})
185186

186187
expect(response.status).toBe(200)
@@ -223,6 +224,7 @@ describe('Fireworks deployment routing', () => {
223224
originalModel: 'minimax/minimax-m2.5',
224225
fetch: mockFetch,
225226
logger,
227+
useCustomDeployment: true,
226228
})
227229

228230
expect(response.status).toBe(200)
@@ -259,6 +261,7 @@ describe('Fireworks deployment routing', () => {
259261
originalModel: 'minimax/minimax-m2.5',
260262
fetch: mockFetch,
261263
logger,
264+
useCustomDeployment: true,
262265
}),
263266
).rejects.toBeInstanceOf(FireworksError)
264267
} finally {
@@ -283,6 +286,7 @@ describe('Fireworks deployment routing', () => {
283286
originalModel: 'minimax/minimax-m2.5',
284287
fetch: mockFetch,
285288
logger,
289+
useCustomDeployment: true,
286290
})
287291

288292
expect(response.status).toBe(200)
@@ -309,6 +313,7 @@ describe('Fireworks deployment routing', () => {
309313
originalModel: 'some-other/model',
310314
fetch: mockFetch,
311315
logger,
316+
useCustomDeployment: true,
312317
})
313318

314319
expect(response.status).toBe(200)
@@ -339,6 +344,7 @@ describe('Fireworks deployment routing', () => {
339344
originalModel: 'minimax/minimax-m2.5',
340345
fetch: mockFetch,
341346
logger,
347+
useCustomDeployment: true,
342348
})
343349

344350
// Non-503 errors from deployment are returned as-is (caller handles them)
@@ -377,6 +383,7 @@ describe('Fireworks deployment routing', () => {
377383
originalModel: 'minimax/minimax-m2.5',
378384
fetch: mockFetch,
379385
logger,
386+
useCustomDeployment: true,
380387
})
381388

382389
expect(logger.info).toHaveBeenCalledTimes(2)

web/src/llm-api/fireworks.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -656,11 +656,13 @@ export async function createFireworksRequestWithFallback(params: {
656656
originalModel: string
657657
fetch: typeof globalThis.fetch
658658
logger: Logger
659+
useCustomDeployment?: boolean
659660
}): Promise<Response> {
660661
const { body, originalModel, fetch, logger } = params
662+
const useCustomDeployment = params.useCustomDeployment ?? FIREWORKS_USE_CUSTOM_DEPLOYMENT
661663
const deploymentModelId = FIREWORKS_DEPLOYMENT_MAP[originalModel]
662664
const shouldTryDeployment =
663-
FIREWORKS_USE_CUSTOM_DEPLOYMENT &&
665+
useCustomDeployment &&
664666
deploymentModelId &&
665667
isDeploymentHours() &&
666668
!isDeploymentCoolingDown()

0 commit comments

Comments
 (0)