void () { FileEditorProvider.EP_FILE_EDITOR_PROVIDER.getPoint().registerExtension(new MyFileEditorProvider(), myFixture.getTestRootDisposable()); VirtualFile file = getFile("/src/1.txt"); assertNotNull(file); FileEditor[] editors = manager.openFile(file, true); assertEquals(2, editors.length); assertEquals("Text", manager.getSelectedEditor(file).getName()); manager.setSelectedEditor(file, "mock"); assertEquals(MyFileEditorProvider.DEFAULT_FILE_EDITOR_NAME, manager.getSelectedEditor(file).getName()); VirtualFile file1 = getFile("/src/2.txt"); manager.openFile(file1, true); assertEquals(MyFileEditorProvider.DEFAULT_FILE_EDITOR_NAME, manager.getSelectedEditor(file).getName()); }