File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
extensions/vscode-api-tests/src/singlefolder-tests Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -357,13 +357,27 @@ import { assertNoRpc, poll } from '../utils';
357357 test ( 'should be defined after selecting all content' , async ( ) => {
358358 const terminal = window . createTerminal ( { name : 'selection test' } ) ;
359359 terminal . show ( ) ;
360+ // Wait for some terminal data
361+ await new Promise < void > ( r => {
362+ const disposable = window . onDidWriteTerminalData ( ( ) => {
363+ disposable . dispose ( ) ;
364+ r ( ) ;
365+ } ) ;
366+ } ) ;
360367 await commands . executeCommand ( 'workbench.action.terminal.selectAll' ) ;
361368 await poll < void > ( ( ) => Promise . resolve ( ) , ( ) => terminal . selection !== undefined , 'selection should be defined' ) ;
362369 terminal . dispose ( ) ;
363370 } ) ;
364371 test ( 'should be undefined after clearing a selection' , async ( ) => {
365372 const terminal = window . createTerminal ( { name : 'selection test' } ) ;
366373 terminal . show ( ) ;
374+ // Wait for some terminal data
375+ await new Promise < void > ( r => {
376+ const disposable = window . onDidWriteTerminalData ( ( ) => {
377+ disposable . dispose ( ) ;
378+ r ( ) ;
379+ } ) ;
380+ } ) ;
367381 await commands . executeCommand ( 'workbench.action.terminal.selectAll' ) ;
368382 await poll < void > ( ( ) => Promise . resolve ( ) , ( ) => terminal . selection !== undefined , 'selection should be defined' ) ;
369383 await commands . executeCommand ( 'workbench.action.terminal.clearSelection' ) ;
You can’t perform that action at this time.
0 commit comments