@@ -108,4 +108,53 @@ describe("MessagesTimeline", () => {
108108 expect ( markup ) . toContain ( "Context compacted" ) ;
109109 expect ( markup ) . toContain ( "Work log" ) ;
110110 } ) ;
111+
112+ it ( "renders the assistant copy button in a disabled state while streaming" , async ( ) => {
113+ const { MessagesTimeline } = await import ( "./MessagesTimeline" ) ;
114+ const markup = renderToStaticMarkup (
115+ < MessagesTimeline
116+ hasMessages
117+ isWorking = { false }
118+ activeTurnInProgress
119+ activeTurnStartedAt = "2026-03-17T19:12:28.000Z"
120+ scrollContainer = { null }
121+ timelineEntries = { [
122+ {
123+ id : "assistant-entry" ,
124+ kind : "message" ,
125+ createdAt : "2026-03-17T19:12:28.000Z" ,
126+ message : {
127+ id : MessageId . make ( "assistant-1" ) ,
128+ role : "assistant" ,
129+ text : "" ,
130+ turnId : "turn-1" as never ,
131+ createdAt : "2026-03-17T19:12:28.000Z" ,
132+ streaming : true ,
133+ } ,
134+ } ,
135+ ] }
136+ completionDividerBeforeEntryId = { null }
137+ completionSummary = { null }
138+ turnDiffSummaryByAssistantMessageId = { new Map ( ) }
139+ nowIso = "2026-03-17T19:12:30.000Z"
140+ expandedWorkGroups = { { } }
141+ onToggleWorkGroup = { ( ) => { } }
142+ changedFilesExpandedByTurnId = { { } }
143+ onSetChangedFilesExpanded = { ( ) => { } }
144+ onOpenTurnDiff = { ( ) => { } }
145+ revertTurnCountByUserMessageId = { new Map ( ) }
146+ onRevertUserMessage = { ( ) => { } }
147+ isRevertingCheckpoint = { false }
148+ onImageExpand = { ( ) => { } }
149+ activeThreadEnvironmentId = { ACTIVE_THREAD_ENVIRONMENT_ID }
150+ markdownCwd = { undefined }
151+ resolvedTheme = "light"
152+ timestampFormat = "locale"
153+ workspaceRoot = { undefined }
154+ /> ,
155+ ) ;
156+
157+ expect ( markup ) . toContain ( 'aria-label="Copy assistant response"' ) ;
158+ expect ( markup ) . toContain ( "disabled" ) ;
159+ } , 10_000 ) ;
111160} ) ;
0 commit comments