@@ -45,14 +45,10 @@ async function expectChatBubbleAbove(page: Page, upperText: string, lowerText: s
4545
4646suite . define ( ( ) => {
4747 it ( "steers ordinary follow-ups when the server default is steer" , async ( ) => {
48- const artifactDir = process . env . OPENCLAW_UI_E2E_ARTIFACT_DIR ?. trim ( ) ;
4948 const context = await suite . newBrowserContext ( {
5049 locale : "en-US" ,
5150 serviceWorkers : "block" ,
5251 viewport : { height : 900 , width : 1280 } ,
53- ...( artifactDir
54- ? { recordVideo : { dir : artifactDir , size : { height : 900 , width : 1280 } } }
55- : { } ) ,
5652 } ) ;
5753 const page = await context . newPage ( ) ;
5854 const runtimeConfig = {
@@ -127,12 +123,6 @@ suite.define(() => {
127123 timeout : 10_000 ,
128124 } ) ;
129125 await queue . getByText ( followUp ) . waitFor ( { timeout : 10_000 } ) ;
130- if ( artifactDir ) {
131- await page . screenshot ( {
132- path : `${ artifactDir } /steer-before-persistence.png` ,
133- fullPage : true ,
134- } ) ;
135- }
136126 await gateway . emitGatewayEvent ( "session.message" , {
137127 activeRunIds : [ activeRunId ] ,
138128 clientRunId : activeRunId ,
@@ -165,19 +155,12 @@ suite.define(() => {
165155 . poll ( ( ) => page . locator ( ".chat-thread .chat-group.user" , { hasText : followUp } ) . count ( ) )
166156 . toBe ( 1 ) ;
167157 await expectChatBubbleAbove ( page , originalPrompt , followUp ) ;
168- if ( artifactDir ) {
169- await page . screenshot ( {
170- path : `${ artifactDir } /steer-after-persistence.png` ,
171- fullPage : true ,
172- } ) ;
173- }
174158 } finally {
175159 await suite . closeBrowserContext ( context ) ;
176160 }
177161 } ) ;
178162
179163 it ( "preserves a non-steer server default for active-run follow-ups" , async ( ) => {
180- const artifactDir = process . env . OPENCLAW_UI_E2E_ARTIFACT_DIR ?. trim ( ) ;
181164 const context = await suite . newBrowserContext ( {
182165 locale : "en-US" ,
183166 serviceWorkers : "block" ,
@@ -206,12 +189,6 @@ suite.define(() => {
206189 await followUpSelect . waitFor ( { state : "visible" , timeout : 10_000 } ) ;
207190 expect ( await followUpSelect . inputValue ( ) ) . toBe ( "server" ) ;
208191 await page . getByText ( "Using server default (followup)" ) . waitFor ( { timeout : 10_000 } ) ;
209- if ( artifactDir ) {
210- await page . screenshot ( {
211- path : `${ artifactDir } /server-followup-setting.png` ,
212- fullPage : true ,
213- } ) ;
214- }
215192 const configPatchCount = ( await gateway . getRequests ( "config.patch" ) ) . length ;
216193 const configGetCount = ( await gateway . getRequests ( "config.get" ) ) . length ;
217194 const overrideConfig = {
@@ -238,12 +215,6 @@ suite.define(() => {
238215 runtimeConfig,
239216 valid : true ,
240217 } ) ;
241- if ( artifactDir ) {
242- await page . screenshot ( {
243- path : `${ artifactDir } /server-followup-override.png` ,
244- fullPage : true ,
245- } ) ;
246- }
247218 await page . getByRole ( "button" , { name : "Reset to server default" } ) . click ( ) ;
248219 await waitForRequests ( gateway , "config.patch" , configPatchCount + 2 ) ;
249220 await waitForRequests ( gateway , "config.get" , configGetCount + 2 ) ;
@@ -276,14 +247,10 @@ suite.define(() => {
276247 } ) ;
277248
278249 it ( "steers a queued follow-up with modified Enter in Enter shortcut mode" , async ( ) => {
279- const artifactDir = process . env . OPENCLAW_UI_E2E_ARTIFACT_DIR ?. trim ( ) ;
280250 const context = await suite . newBrowserContext ( {
281251 locale : "en-US" ,
282252 serviceWorkers : "block" ,
283253 viewport : { height : 900 , width : 1280 } ,
284- ...( artifactDir
285- ? { recordVideo : { dir : artifactDir , size : { height : 900 , width : 1280 } } }
286- : { } ) ,
287254 } ) ;
288255 const page = await context . newPage ( ) ;
289256 const gateway = await installMockGateway ( page ) ;
@@ -303,28 +270,6 @@ suite.define(() => {
303270
304271 const steerText = "steer this keyboard follow-up now" ;
305272 await composer . fill ( steerText ) ;
306- const enterQueueButton = page . getByRole ( "button" , { name : "Queue message" } ) ;
307- const enterTooltip = await enterQueueButton
308- . locator ( ".." )
309- . evaluate ( ( element ) => ( element as HTMLElement & { content ?: string } ) . content ) ;
310- expect ( enterTooltip ) . toBe ( "Queue ⏎ · Steer ⌘/Ctrl+Enter" ) ;
311- if ( artifactDir ) {
312- await enterQueueButton . hover ( ) ;
313- await expect
314- . poll ( ( ) =>
315- enterQueueButton . evaluate ( ( button ) => {
316- const tooltip = button
317- . closest ( "openclaw-tooltip" )
318- ?. shadowRoot ?. querySelector ( "wa-tooltip" ) ;
319- return ( tooltip as ( HTMLElement & { open ?: boolean } ) | null ) ?. open === true ;
320- } ) ,
321- )
322- . toBe ( true ) ;
323- await page . screenshot ( {
324- path : `${ artifactDir } /queue-steer-shortcut.png` ,
325- fullPage : true ,
326- } ) ;
327- }
328273 await composer . press ( "Control+Enter" ) ;
329274
330275 const firstRunSends = await waitForRequests ( gateway , "chat.send" , 2 ) ;
@@ -338,17 +283,6 @@ suite.define(() => {
338283 } ) ;
339284 const steeredRow = page . locator ( ".chat-queue__item--steered" , { hasText : steerText } ) ;
340285 await steeredRow . waitFor ( { timeout : 10_000 } ) ;
341- await gateway . emitGatewayEvent ( "chat" , {
342- runId : requireString ( steerParams . idempotencyKey , "steer send id" ) ,
343- sessionKey : "main" ,
344- state : "final" ,
345- } ) ;
346- await steeredRow . waitFor ( { state : "detached" , timeout : 10_000 } ) ;
347-
348- await gateway . emitChatFinal ( { runId : firstRunId , text : "First shortcut run finished." } ) ;
349- await page
350- . getByRole ( "button" , { name : "Stop generating" } )
351- . waitFor ( { state : "detached" , timeout : 10_000 } ) ;
352286 } finally {
353287 await suite . closeBrowserContext ( context ) ;
354288 }
@@ -377,11 +311,6 @@ suite.define(() => {
377311
378312 const queuedText = "leave this modifier follow-up queued" ;
379313 await composer . fill ( queuedText ) ;
380- const queueButton = page . getByRole ( "button" , { name : "Queue message" } ) ;
381- const tooltip = await queueButton
382- . locator ( ".." )
383- . evaluate ( ( element ) => ( element as HTMLElement & { content ?: string } ) . content ) ;
384- expect ( tooltip ) . toBe ( "Queue" ) ;
385314 await composer . press ( "Control+Enter" ) ;
386315
387316 const queuedRow = page . locator ( ".chat-queue__item" , { hasText : queuedText } ) ;
@@ -459,14 +388,10 @@ suite.define(() => {
459388 } ) ;
460389
461390 it ( "dismisses an informational steer notice when the steer request lands" , async ( ) => {
462- const artifactDir = process . env . OPENCLAW_UI_E2E_ARTIFACT_DIR ?. trim ( ) ;
463391 const context = await suite . newBrowserContext ( {
464392 locale : "en-US" ,
465393 serviceWorkers : "block" ,
466394 viewport : { height : 900 , width : 1280 } ,
467- ...( artifactDir
468- ? { recordVideo : { dir : artifactDir , size : { height : 900 , width : 1280 } } }
469- : { } ) ,
470395 } ) ;
471396 const page = await context . newPage ( ) ;
472397 const gateway = await installMockGateway ( page ) ;
@@ -548,10 +473,6 @@ suite.define(() => {
548473 infoSubtle,
549474 } ;
550475 } ) ;
551- if ( artifactDir ) {
552- await page . screenshot ( { path : `${ artifactDir } /steer-pending.png` , fullPage : true } ) ;
553- }
554-
555476 await gateway . emitGatewayEvent ( "chat" , {
556477 runId : steerRunId ,
557478 sessionKey : "main" ,
@@ -560,9 +481,6 @@ suite.define(() => {
560481 await row . waitFor ( { state : "detached" , timeout : 10_000 } ) ;
561482 await page . getByText ( steerText , { exact : true } ) . waitFor ( { timeout : 10_000 } ) ;
562483 await expectChatBubbleAbove ( page , "keep this run active" , steerText ) ;
563- if ( artifactDir ) {
564- await page . screenshot ( { path : `${ artifactDir } /steer-landed.png` , fullPage : true } ) ;
565- }
566484
567485 expect ( pendingPresentation ) . toMatchObject ( {
568486 badgeColor : pendingPresentation . infoColor ,
0 commit comments