@@ -307,100 +307,6 @@ suite('Editor service', () => {
307307 } ) ;
308308 } ) ;
309309
310- // test('close editor does not dispose when editor opened in other group (diff input)', function () {
311- // const partInstantiator = workbenchInstantiationService();
312-
313- // const part = partInstantiator.createInstance(EditorPart, 'id', false);
314- // part.create(document.createElement('div'));
315- // part.layout(new Dimension(400, 300));
316-
317- // const testInstantiationService = partInstantiator.createChild(new ServiceCollection([IEditorGroupsService, part]));
318-
319- // const service: IEditorService = testInstantiationService.createInstance(EditorService);
320-
321- // const input = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource-close2'));
322- // const otherInput = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource2-close2'));
323- // const diffInput = new DiffEditorInput('name', 'description', input, otherInput);
324-
325- // const rootGroup = part.activeGroup;
326- // const rightGroup = part.addGroup(rootGroup, GroupDirection.RIGHT);
327-
328- // // Open input
329- // return service.openEditor(diffInput, { pinned: true }).then(editor => {
330- // return service.openEditor(diffInput, { pinned: true }, rightGroup).then(editor => {
331-
332- // // Close input
333- // return rootGroup.closeEditor(diffInput).then(() => {
334- // assert.equal(diffInput.isDisposed(), false);
335- // assert.equal(input.isDisposed(), false);
336- // assert.equal(otherInput.isDisposed(), false);
337-
338- // return rightGroup.closeEditor(diffInput).then(() => {
339- // assert.equal(diffInput.isDisposed(), true);
340- // assert.equal(input.isDisposed(), true);
341- // assert.equal(otherInput.isDisposed(), true);
342- // });
343- // });
344- // });
345- // });
346- // });
347-
348- // test('close editor disposes properly (diff input)', function () {
349- // const partInstantiator = workbenchInstantiationService();
350-
351- // const part = partInstantiator.createInstance(EditorPart, 'id', false);
352- // part.create(document.createElement('div'));
353- // part.layout(new Dimension(400, 300));
354-
355- // const testInstantiationService = partInstantiator.createChild(new ServiceCollection([IEditorGroupsService, part]));
356-
357- // const service: IEditorService = testInstantiationService.createInstance(EditorService);
358-
359- // const input = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource-close3'));
360- // const otherInput = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource2-close3'));
361- // const diffInput = new DiffEditorInput('name', 'description', input, otherInput);
362-
363- // // Open input
364- // return service.openEditor(diffInput, { pinned: true }).then(editor => {
365-
366- // // Close input
367- // return editor.group.closeEditor(diffInput).then(() => {
368- // assert.equal(diffInput.isDisposed(), true);
369- // assert.equal(otherInput.isDisposed(), true);
370- // assert.equal(input.isDisposed(), true);
371- // });
372- // });
373- // });
374-
375- // test('close editor disposes properly (diff input, left side still opened)', function () {
376- // const partInstantiator = workbenchInstantiationService();
377-
378- // const part = partInstantiator.createInstance(EditorPart, 'id', false);
379- // part.create(document.createElement('div'));
380- // part.layout(new Dimension(400, 300));
381-
382- // const testInstantiationService = partInstantiator.createChild(new ServiceCollection([IEditorGroupsService, part]));
383-
384- // const service: IEditorService = testInstantiationService.createInstance(EditorService);
385-
386- // const input = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource-close4'));
387- // const otherInput = testInstantiationService.createInstance(TestEditorInput, URI.parse('my://resource2-close4'));
388- // const diffInput = new DiffEditorInput('name', 'description', input, otherInput);
389-
390- // // Open input
391- // return service.openEditor(diffInput, { pinned: true }).then(editor => {
392- // return service.openEditor(input, { pinned: true }).then(editor => {
393-
394- // // Close input
395- // return editor.group.closeEditor(diffInput).then(() => {
396- // assert.equal(diffInput.isDisposed(), true);
397- // assert.equal(otherInput.isDisposed(), true);
398- // assert.equal(input.isDisposed(), false);
399- // });
400- // });
401- // });
402- // });
403-
404310 test ( 'open to the side' , function ( ) {
405311 const partInstantiator = workbenchInstantiationService ( ) ;
406312
0 commit comments