mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-31 19:16:29 +00:00
fmt(js): npm run fix on merge (#66457)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
parent
9930c2b47f
commit
29e3983fa8
4 changed files with 15 additions and 17 deletions
|
|
@ -2,12 +2,7 @@ import { cleanup, render, screen } from '@testing-library/react'
|
|||
import { afterEach, describe, expect, it } from 'vitest'
|
||||
|
||||
import type { ChatBarState } from '@/app/chat/composer/types'
|
||||
import {
|
||||
$activeSessionId,
|
||||
$currentModel,
|
||||
setCurrentModel,
|
||||
setCurrentModelSource
|
||||
} from '@/store/session'
|
||||
import { $activeSessionId, $currentModel, setCurrentModel, setCurrentModelSource } from '@/store/session'
|
||||
|
||||
import { ModelPill } from './model-pill'
|
||||
|
||||
|
|
|
|||
|
|
@ -90,7 +90,9 @@ export function ModelPill({
|
|||
)
|
||||
: PILL
|
||||
|
||||
const baseTitle = currentProvider ? copy.modelTitle(currentProvider, currentModel || copy.modelNone) : copy.switchModel
|
||||
const baseTitle = currentProvider
|
||||
? copy.modelTitle(currentProvider, currentModel || copy.modelNone)
|
||||
: copy.switchModel
|
||||
const title = pinnedOverride ? `${baseTitle} — ${copy.modelPinned}` : baseTitle
|
||||
|
||||
if (!model.modelMenuContent) {
|
||||
|
|
|
|||
|
|
@ -139,9 +139,7 @@ function ChatHeader({
|
|||
'calc(100vw - var(--titlebar-content-inset,0px) - var(--titlebar-tools-right) - var(--titlebar-tools-width) - 1.5rem)'
|
||||
}}
|
||||
>
|
||||
{showProfileTag && (
|
||||
<ProfileTag className="pointer-events-auto mr-1.5" profile={activeStoredSession?.profile} />
|
||||
)}
|
||||
{showProfileTag && <ProfileTag className="pointer-events-auto mr-1.5" profile={activeStoredSession?.profile} />}
|
||||
<SessionActionsMenu
|
||||
align="start"
|
||||
onDelete={selectedSessionId ? onDeleteSelectedSession : undefined}
|
||||
|
|
|
|||
|
|
@ -353,9 +353,9 @@ describe('ship flow', () => {
|
|||
await createOrOpenPr()
|
||||
|
||||
expect(review.createPr).not.toHaveBeenCalled()
|
||||
expect((window.hermesDesktop as unknown as { openExternal: ReturnType<typeof vi.fn> }).openExternal).toHaveBeenCalledWith(
|
||||
'https://example.com/pr/9'
|
||||
)
|
||||
expect(
|
||||
(window.hermesDesktop as unknown as { openExternal: ReturnType<typeof vi.fn> }).openExternal
|
||||
).toHaveBeenCalledWith('https://example.com/pr/9')
|
||||
})
|
||||
|
||||
it('createOrOpenPr creates a PR when none exists, then opens it', async () => {
|
||||
|
|
@ -365,15 +365,18 @@ describe('ship flow', () => {
|
|||
await createOrOpenPr()
|
||||
|
||||
expect(review.createPr).toHaveBeenCalledWith('/repo')
|
||||
expect((window.hermesDesktop as unknown as { openExternal: ReturnType<typeof vi.fn> }).openExternal).toHaveBeenCalledWith(
|
||||
'https://example.com/pr/new'
|
||||
)
|
||||
expect(
|
||||
(window.hermesDesktop as unknown as { openExternal: ReturnType<typeof vi.fn> }).openExternal
|
||||
).toHaveBeenCalledWith('https://example.com/pr/new')
|
||||
})
|
||||
})
|
||||
|
||||
describe('refreshShipInfo', () => {
|
||||
it('populates ship info from the bridge', async () => {
|
||||
const info: HermesReviewShipInfo = { ghReady: true, pr: { url: 'https://example.com/pr/3' } } as HermesReviewShipInfo
|
||||
const info: HermesReviewShipInfo = {
|
||||
ghReady: true,
|
||||
pr: { url: 'https://example.com/pr/3' }
|
||||
} as HermesReviewShipInfo
|
||||
stubReview({ shipInfo: vi.fn(async () => info) })
|
||||
|
||||
await refreshShipInfo()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue