File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import { container } from 'tsyringe';
33import { EditorService , StatusBarService , BuiltinService } from 'mo/services' ;
44import { EditorController } from '../editor' ;
55import { editor as MonacoEditor , IDisposable , Position } from 'mo/monaco' ;
6+ import { IEditorTab } from 'mo/model' ;
67
78const editorController = container . resolve ( EditorController ) ;
89const editorService = container . resolve ( EditorService ) ;
@@ -35,10 +36,14 @@ describe('The ediotr controller', () => {
3536 return { } as IDisposable ;
3637 } ) ;
3738 editorInstance . getPosition = jest . fn ( ( ) => position ) ;
38-
39- const testTab = {
40- id : 'testTab' ,
41- name : 'testTab' ,
39+ const tabName = 'testTab' ;
40+ const testTab : IEditorTab = {
41+ id : tabName ,
42+ name : tabName ,
43+ renderPane : ( tabData , tab , group ) => {
44+ expect ( tab ?. id ) . toEqual ( tabName ) ;
45+ return ;
46+ } ,
4247 } ;
4348 editorService . open ( testTab ) ;
4449 const { current } = editorService . getState ( ) ;
You can’t perform that action at this time.
0 commit comments