Download apps/desktop/src/components/assistant-ui/thread/transcript-window.test.ts from SaylorTwift/hermes-agent: direct link, hf CLI and curl.
- Browser
- Download file 619 Bytes
-
https://huggingface.co/SaylorTwift/hermes-agent/resolve/main/apps/desktop/src/components/assistant-ui/thread/transcript-window.test.ts
- Command line
-
hf download hf://SaylorTwift/hermes-agent/apps/desktop/src/components/assistant-ui/thread/transcript-window.test.ts
-
curl -L -o transcript-window.test.ts https://huggingface.co/SaylorTwift/hermes-agent/resolve/main/apps/desktop/src/components/assistant-ui/thread/transcript-window.test.ts
619 Bytes
| import { describe, expect, it } from 'vitest' | |
| import { resolveShowEarlierAction } from './transcript-window' | |
| describe('resolveShowEarlierAction', () => { | |
| it('spends the already-materialized DOM page first', () => { | |
| expect(resolveShowEarlierAction(3, true)).toBe('dom') | |
| expect(resolveShowEarlierAction(3, false)).toBe('dom') | |
| }) | |
| it('expands the store window once the DOM page is exhausted', () => { | |
| expect(resolveShowEarlierAction(0, true)).toBe('window') | |
| }) | |
| it('is a no-op when neither DOM nor store has older content', () => { | |
| expect(resolveShowEarlierAction(0, false)).toBe(null) | |
| }) | |
| }) | |