spacehub

surshar / claude-code

Claude Code is an agentic coding tool that lives in your terminal, understands your codebase, and helps you code faster by executing routine tasks, explaining complex code, and handling git workflows - all through natural language commands.

Built by Anthropic · github.com/anthropics

claude-code / mods / diff / tests / fixtures / edited-transcript.ts
14 lines · 460 BRaw
1import type { SessionMessage } from 'claude-code'
2
3import { editPatchOf } from './edit-patch-of.js'
4import TurnDiffsOf from './turn-diffs-of'
5
6/**
7 * A transcript a resumed session brings back whose one turn edited a file:
8 * the prompt, the Edit that landed, its result.
9 */
10export const EDITED_TRANSCRIPT: readonly SessionMessage[] = [
11 TurnDiffsOf.promptOf('change a to b'),
12 TurnDiffsOf.editsOf(editPatchOf(['-a', '+b'])),
13 TurnDiffsOf.toolResults(),
14]