@@ -121,7 +121,9 @@ describe('DesktopCommandExecutor', () => {
121121 const { adapter, executor, overlay } = createExecutor ( ) ;
122122
123123 await executor . execute ( command ( 'keyboard.key' , { key : 'Enter' } ) ) ;
124+ await executor . execute ( command ( 'keyboard.key' , { key : 'F12' } ) ) ;
124125 await executor . execute ( command ( 'keyboard.shortcut' , { keys : [ 'Ctrl' , 'C' ] } ) ) ;
126+ await executor . execute ( command ( 'keyboard.shortcut' , { keys : [ 'Ctrl' , 'F5' ] } ) ) ;
125127 await executor . execute ( command ( 'keyboard.typeText' , { text : 'Hello' } ) ) ;
126128 await executor . execute ( command ( 'media.control' , { action : 'playPause' } ) ) ;
127129 await executor . execute ( command ( 'window.control' , { action : 'switchNext' } ) ) ;
@@ -130,28 +132,30 @@ describe('DesktopCommandExecutor', () => {
130132 expect ( pingResult ) . toEqual ( { ok : true } ) ;
131133 expect ( adapter . calls ) . toEqual ( [
132134 { method : 'pressKey' , args : [ 'Enter' ] } ,
135+ { method : 'pressKey' , args : [ 'F12' ] } ,
133136 { method : 'pressShortcut' , args : [ [ 'Ctrl' , 'C' ] ] } ,
137+ { method : 'pressShortcut' , args : [ [ 'Ctrl' , 'F5' ] ] } ,
134138 { method : 'typeText' , args : [ 'Hello' ] } ,
135139 { method : 'mediaControl' , args : [ 'playPause' ] } ,
136140 { method : 'controlWindow' , args : [ 'switchNext' ] }
137141 ] ) ;
138142 expect ( overlay . events ) . toHaveLength ( 0 ) ;
139143 expect ( overlay . activeCount ) . toBe ( 0 ) ;
140- expect ( overlay . hideCount ) . toBe ( 6 ) ;
144+ expect ( overlay . hideCount ) . toBe ( 8 ) ;
141145 } ) ;
142146
143147 it ( 'executes non-movement no-response commands without coalescing' , async ( ) => {
144148 const { adapter, executor, overlay } = createExecutor ( ) ;
145149
146150 await executor . execute ( command ( 'mouse.click' , { button : 'left' } , { responseMode : 'none' } ) ) ;
147151 await executor . execute ( command ( 'mouse.scroll' , { dx : 0 , dy : - 3 } , { responseMode : 'none' } ) ) ;
148- await executor . execute ( command ( 'keyboard.key' , { key : 'Enter ' } , { responseMode : 'none' } ) ) ;
152+ await executor . execute ( command ( 'keyboard.key' , { key : 'F12 ' } , { responseMode : 'none' } ) ) ;
149153 await executor . execute ( command ( 'window.control' , { action : 'switchNext' } , { responseMode : 'none' } ) ) ;
150154
151155 expect ( adapter . calls ) . toEqual ( [
152156 { method : 'clickMouse' , args : [ 'left' ] } ,
153157 { method : 'scrollMouse' , args : [ { dx : 0 , dy : - 3 } ] } ,
154- { method : 'pressKey' , args : [ 'Enter ' ] } ,
158+ { method : 'pressKey' , args : [ 'F12 ' ] } ,
155159 { method : 'controlWindow' , args : [ 'switchNext' ] }
156160 ] ) ;
157161 expect ( overlay . events ) . toEqual ( [ 'click' ] ) ;
0 commit comments